From 9d16152e3932b2c5191e71c16d1dd603200e7414 Mon Sep 17 00:00:00 2001 From: gugug Date: Sat, 20 Jun 2020 23:59:23 +0800 Subject: [PATCH] Stop to use the __future__ module. The __future__ module [1] was used in this context to ensure compatibility between python 2 and python 3. We previously dropped the support of python 2.7 and now we only support python 3 so we don't need to continue to use this module and the imports listed below. Change-Id: I19fbdebe406575d2567f98a322ff68e6e992fac7 --- tripleoclient/heat_launcher.py | 1 - tripleoclient/utils.py | 1 - tripleoclient/v1/overcloud_cell.py | 2 -- tripleoclient/v1/overcloud_deploy.py | 1 - tripleoclient/v1/overcloud_export.py | 2 -- tripleoclient/v1/overcloud_image.py | 2 -- tripleoclient/v1/overcloud_netenv_validate.py | 1 - tripleoclient/v1/overcloud_plan.py | 2 -- tripleoclient/v1/overcloud_roles.py | 2 -- tripleoclient/v1/tripleo_config.py | 1 - tripleoclient/v1/tripleo_deploy.py | 1 - tripleoclient/v1/tripleo_launch_heat.py | 1 - tripleoclient/workflows/baremetal.py | 2 -- tripleoclient/workflows/deployment.py | 1 - tripleoclient/workflows/package_update.py | 1 - tripleoclient/workflows/scale.py | 1 - 16 files changed, 22 deletions(-) diff --git a/tripleoclient/heat_launcher.py b/tripleoclient/heat_launcher.py index e6e236652..3181c4a19 100644 --- a/tripleoclient/heat_launcher.py +++ b/tripleoclient/heat_launcher.py @@ -12,7 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. # -from __future__ import print_function import datetime import grp diff --git a/tripleoclient/utils.py b/tripleoclient/utils.py index 3cbe63ca3..93614e747 100644 --- a/tripleoclient/utils.py +++ b/tripleoclient/utils.py @@ -13,7 +13,6 @@ # under the License. # -from __future__ import print_function import collections try: diff --git a/tripleoclient/v1/overcloud_cell.py b/tripleoclient/v1/overcloud_cell.py index 73b4b390d..83181b522 100644 --- a/tripleoclient/v1/overcloud_cell.py +++ b/tripleoclient/v1/overcloud_cell.py @@ -10,8 +10,6 @@ # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function - from datetime import datetime import logging import os.path diff --git a/tripleoclient/v1/overcloud_deploy.py b/tripleoclient/v1/overcloud_deploy.py index 5d7e3ba61..15bbcff2e 100644 --- a/tripleoclient/v1/overcloud_deploy.py +++ b/tripleoclient/v1/overcloud_deploy.py @@ -12,7 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. # -from __future__ import print_function import argparse import logging diff --git a/tripleoclient/v1/overcloud_export.py b/tripleoclient/v1/overcloud_export.py index 074a4efeb..098c8afbb 100644 --- a/tripleoclient/v1/overcloud_export.py +++ b/tripleoclient/v1/overcloud_export.py @@ -10,8 +10,6 @@ # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function - from datetime import datetime import logging import os.path diff --git a/tripleoclient/v1/overcloud_image.py b/tripleoclient/v1/overcloud_image.py index cb8ce52d9..46ccb9f21 100644 --- a/tripleoclient/v1/overcloud_image.py +++ b/tripleoclient/v1/overcloud_image.py @@ -13,8 +13,6 @@ # under the License. # -from __future__ import print_function - import abc import collections from datetime import datetime diff --git a/tripleoclient/v1/overcloud_netenv_validate.py b/tripleoclient/v1/overcloud_netenv_validate.py index cc9a19031..cd06acf9b 100644 --- a/tripleoclient/v1/overcloud_netenv_validate.py +++ b/tripleoclient/v1/overcloud_netenv_validate.py @@ -12,7 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. # -from __future__ import print_function import itertools import logging diff --git a/tripleoclient/v1/overcloud_plan.py b/tripleoclient/v1/overcloud_plan.py index ce3aaed4c..8c1e1e223 100644 --- a/tripleoclient/v1/overcloud_plan.py +++ b/tripleoclient/v1/overcloud_plan.py @@ -10,8 +10,6 @@ # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function - import logging import os.path diff --git a/tripleoclient/v1/overcloud_roles.py b/tripleoclient/v1/overcloud_roles.py index 3b0037114..61d4c765f 100644 --- a/tripleoclient/v1/overcloud_roles.py +++ b/tripleoclient/v1/overcloud_roles.py @@ -13,8 +13,6 @@ # under the License. # -from __future__ import print_function - import collections import os import sys diff --git a/tripleoclient/v1/tripleo_config.py b/tripleoclient/v1/tripleo_config.py index 3cddbd322..4d0e72d75 100644 --- a/tripleoclient/v1/tripleo_config.py +++ b/tripleoclient/v1/tripleo_config.py @@ -12,7 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. # -from __future__ import print_function import argparse import logging diff --git a/tripleoclient/v1/tripleo_deploy.py b/tripleoclient/v1/tripleo_deploy.py index b6d20cb04..9eaf2ea3b 100644 --- a/tripleoclient/v1/tripleo_deploy.py +++ b/tripleoclient/v1/tripleo_deploy.py @@ -12,7 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. # -from __future__ import print_function import argparse import json diff --git a/tripleoclient/v1/tripleo_launch_heat.py b/tripleoclient/v1/tripleo_launch_heat.py index 65658e2e6..ac61e5e91 100644 --- a/tripleoclient/v1/tripleo_launch_heat.py +++ b/tripleoclient/v1/tripleo_launch_heat.py @@ -12,7 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. # -from __future__ import print_function import argparse import getpass diff --git a/tripleoclient/workflows/baremetal.py b/tripleoclient/workflows/baremetal.py index 70512f736..786d9fd00 100644 --- a/tripleoclient/workflows/baremetal.py +++ b/tripleoclient/workflows/baremetal.py @@ -12,8 +12,6 @@ # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function - import six from tripleo_common.actions import baremetal diff --git a/tripleoclient/workflows/deployment.py b/tripleoclient/workflows/deployment.py index 5252532f4..cb7e09897 100644 --- a/tripleoclient/workflows/deployment.py +++ b/tripleoclient/workflows/deployment.py @@ -9,7 +9,6 @@ # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function import copy import getpass diff --git a/tripleoclient/workflows/package_update.py b/tripleoclient/workflows/package_update.py index d947f938f..4052fbb2f 100644 --- a/tripleoclient/workflows/package_update.py +++ b/tripleoclient/workflows/package_update.py @@ -9,7 +9,6 @@ # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function from heatclient.common import event_utils from tripleo_common.utils import plan diff --git a/tripleoclient/workflows/scale.py b/tripleoclient/workflows/scale.py index 07c631027..a920a1862 100644 --- a/tripleoclient/workflows/scale.py +++ b/tripleoclient/workflows/scale.py @@ -12,7 +12,6 @@ # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. -from __future__ import print_function from heatclient.common import event_utils from tripleo_common.actions import scale