Repository: AcademySoftwareFoundation/rez (language: python)

Issue:
Remove `from __future__ import print_function` from the code base
Remove `from __future__ import print_function` from the code base. This import is not necessary anymore now that we dropped support for Python 2.

Code in `rez.vendor` should be left untouched.


Discussion / hints:

Fix patch:
diff --git a/.github/scripts/store_benchmark.py b/.github/scripts/store_benchmark.py
index d8cbb8c1e..73315ae7c 100644
--- a/.github/scripts/store_benchmark.py
+++ b/.github/scripts/store_benchmark.py
@@ -1,4 +1,3 @@
-from __future__ import print_function
 import os
 import os.path
 import json
diff --git a/.github/scripts/validate_benchmark.py b/.github/scripts/validate_benchmark.py
index 1db42a548..9d57e03cf 100644
--- a/.github/scripts/validate_benchmark.py
+++ b/.github/scripts/validate_benchmark.py
@@ -1,4 +1,3 @@
-from __future__ import print_function
 import os.path
 import sys
 import json
diff --git a/example_extensions/hello_cmd/setup.py b/example_extensions/hello_cmd/setup.py
index e890b3951..0f9617c1c 100644
--- a/example_extensions/hello_cmd/setup.py
+++ b/example_extensions/hello_cmd/setup.py
@@ -2,7 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function, with_statement
 from setuptools import setup
 
 
diff --git a/install.py b/install.py
index ce77b244e..78bff3550 100644
--- a/install.py
+++ b/install.py
@@ -6,8 +6,6 @@
 This script uses venv/virtualenv to create a standalone, production-ready Rez
 installation in the specified directory.
 """
-from __future__ import print_function
-
 import argparse
 import os
 import sys
diff --git a/release-rez.py b/release-rez.py
index 166083914..03ea0744c 100644
--- a/release-rez.py
+++ b/release-rez.py
@@ -7,7 +7,6 @@
 
 Read RELEASE.md before using this utility.
 """
-from __future__ import print_function
 import argparse
 import os
 from datetime import date
diff --git a/repository/hello_world_py/1.0.0/python/hello_world.py b/repository/hello_world_py/1.0.0/python/hello_world.py
index bedf75984..e64f971eb 100644
--- a/repository/hello_world_py/1.0.0/python/hello_world.py
+++ b/repository/hello_world_py/1.0.0/python/hello_world.py
@@ -1,5 +1,2 @@
-from __future__ import print_function
-
-
 def hello():
     print("Hello world!")
diff --git a/repository/tbb/4.3/install.py b/repository/tbb/4.3/install.py
index a7289c4c3..a9eb353ac 100644
--- a/repository/tbb/4.3/install.py
+++ b/repository/tbb/4.3/install.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 import sys
 import shutil
 import os
diff --git a/setup.py b/setup.py
index 5bd6d8c7d..34b9b396d 100644
--- a/setup.py
+++ b/setup.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function, with_statement
-
 import fnmatch
 import os
 import os.path
diff --git a/src/build_utils/license/change_copyright b/src/build_utils/license/change_copyright
index 8ce5a803e..4af68d2dc 100755
--- a/src/build_utils/license/change_copyright
+++ b/src/build_utils/license/change_copyright
@@ -2,7 +2,6 @@
 #
 # dumb script to update copyright notice in a py sourcefile
 #
-from __future__ import print_function
 import argparse
 import sys
 import os
diff --git a/src/rez/__init__.py b/src/rez/__init__.py
index f9dd5ab90..be0a91c2e 100644
--- a/src/rez/__init__.py
+++ b/src/rez/__init__.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.utils._version import _rez_version
 import rez.deprecations
 import sys
diff --git a/src/rez/backport/zipfile.py b/src/rez/backport/zipfile.py
index 233231856..09624f902 100644
--- a/src/rez/backport/zipfile.py
+++ b/src/rez/backport/zipfile.py
@@ -1,2 +1,1 @@
-from __future__ import absolute_import
 from zipfile import *
diff --git a/src/rez/bind/PyQt.py b/src/rez/bind/PyQt.py
index dd059d466..4645bf672 100644
--- a/src/rez/bind/PyQt.py
+++ b/src/rez/bind/PyQt.py
@@ -5,7 +5,6 @@
 """
 Binds the python PyQt module as a rez package.
 """
-from __future__ import absolute_import
 from rez.bind import _pymodule
 from rez.bind._utils import get_version_in_python
 
diff --git a/src/rez/bind/PySide.py b/src/rez/bind/PySide.py
index 7a22ae5bc..8ccb2afc7 100644
--- a/src/rez/bind/PySide.py
+++ b/src/rez/bind/PySide.py
@@ -5,7 +5,6 @@
 """
 Binds the python PySide module as a rez package.
 """
-from __future__ import absolute_import
 from rez.bind import _pymodule
 
 
diff --git a/src/rez/bind/_pymodule.py b/src/rez/bind/_pymodule.py
index 0f51dc747..0c265bbdd 100644
--- a/src/rez/bind/_pymodule.py
+++ b/src/rez/bind/_pymodule.py
@@ -9,8 +9,6 @@
 the current python interpreter - this is rez's, inside its installation
 virtualenv.
 """
-from __future__ import absolute_import, print_function
-
 from rez.bind._utils import check_version, find_exe, make_dirs, \
     get_version_in_python, run_python_command, log
 from rez.package_maker import make_package
diff --git a/src/rez/bind/_utils.py b/src/rez/bind/_utils.py
index 950c18436..395571cda 100644
--- a/src/rez/bind/_utils.py
+++ b/src/rez/bind/_utils.py
@@ -5,7 +5,6 @@
 """
 Utility functions for bind modules.
 """
-from __future__ import absolute_import
 from rez.version import Version
 from rez.exceptions import RezBindError
 from rez.config import config
diff --git a/src/rez/bind/arch.py b/src/rez/bind/arch.py
index 146317694..531ff2f75 100644
--- a/src/rez/bind/arch.py
+++ b/src/rez/bind/arch.py
@@ -5,7 +5,6 @@
 """
 Creates the system architecture package.
 """
-from __future__ import absolute_import
 from rez.package_maker import make_package
 from rez.version import Version
 from rez.bind._utils import check_version
diff --git a/src/rez/bind/cmake.py b/src/rez/bind/cmake.py
index 33ad5130c..8489a3566 100644
--- a/src/rez/bind/cmake.py
+++ b/src/rez/bind/cmake.py
@@ -5,7 +5,6 @@
 """
 Binds a cmake executable as a rez package.
 """
-from __future__ import absolute_import
 from rez.package_maker import make_package
 from rez.bind._utils import check_version, find_exe, extract_version, make_dirs
 from rez.utils.platform_ import platform_
diff --git a/src/rez/bind/gcc.py b/src/rez/bind/gcc.py
index 4d99fa811..8377d7d85 100644
--- a/src/rez/bind/gcc.py
+++ b/src/rez/bind/gcc.py
@@ -2,7 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import absolute_import
 from rez.bind._utils import find_exe, extract_version, make_dirs, log
 from rez.package_maker import make_package
 from rez.utils.lint_helper import env
diff --git a/src/rez/bind/hello_world.py b/src/rez/bind/hello_world.py
index b973c1ee6..c98fad65b 100644
--- a/src/rez/bind/hello_world.py
+++ b/src/rez/bind/hello_world.py
@@ -9,8 +9,6 @@
 requirement. This is not typical! This package is intended as a very simple test
 case, and for that reason we do not want any dependencies.
 """
-from __future__ import absolute_import, print_function
-
 from rez.package_maker import make_package
 from rez.version import Version
 from rez.utils.lint_helper import env
diff --git a/src/rez/bind/os.py b/src/rez/bind/os.py
index 28fe9d2e0..33af3115b 100644
--- a/src/rez/bind/os.py
+++ b/src/rez/bind/os.py
@@ -5,7 +5,6 @@
 """
 Creates the operating system package.
 """
-from __future__ import absolute_import
 from rez.package_maker import make_package
 from rez.version import Version
 from rez.bind._utils import check_version
diff --git a/src/rez/bind/pip.py b/src/rez/bind/pip.py
index 416d20b2b..3763011d0 100644
--- a/src/rez/bind/pip.py
+++ b/src/rez/bind/pip.py
@@ -5,7 +5,6 @@
 """
 Binds the python pip module as a rez package.
 """
-from __future__ import absolute_import
 from rez.bind import _pymodule
 
 
diff --git a/src/rez/bind/platform.py b/src/rez/bind/platform.py
index 5aac37c7c..f998167d5 100644
--- a/src/rez/bind/platform.py
+++ b/src/rez/bind/platform.py
@@ -5,7 +5,6 @@
 """
 Creates the system platform package.
 """
-from __future__ import absolute_import
 from rez.package_maker import make_package
 from rez.version import Version
 from rez.bind._utils import check_version
diff --git a/src/rez/bind/python.py b/src/rez/bind/python.py
index a9338feb7..0c0f3b036 100644
--- a/src/rez/bind/python.py
+++ b/src/rez/bind/python.py
@@ -5,7 +5,6 @@
 """
 Binds a python executable as a rez package.
 """
-from __future__ import absolute_import
 from rez.bind._utils import check_version, find_exe, extract_version, \
     make_dirs, log, run_python_command
 from rez.package_maker import make_package
diff --git a/src/rez/bind/rez.py b/src/rez/bind/rez.py
index 620aeda51..427d31482 100644
--- a/src/rez/bind/rez.py
+++ b/src/rez/bind/rez.py
@@ -5,7 +5,6 @@
 """
 Binds rez itself as a rez package.
 """
-from __future__ import absolute_import
 import rez
 from rez.package_maker import make_package
 from rez.bind._utils import check_version
diff --git a/src/rez/bind/rezgui.py b/src/rez/bind/rezgui.py
index 844c32ecc..17fa01b81 100644
--- a/src/rez/bind/rezgui.py
+++ b/src/rez/bind/rezgui.py
@@ -5,7 +5,6 @@
 """
 Binds rez-gui as a rez package.
 """
-from __future__ import absolute_import
 import rez
 from rez.package_maker import make_package
 from rez.bind._utils import check_version, make_dirs
diff --git a/src/rez/bind/setuptools.py b/src/rez/bind/setuptools.py
index d96df211e..61d0d5b7a 100644
--- a/src/rez/bind/setuptools.py
+++ b/src/rez/bind/setuptools.py
@@ -5,7 +5,6 @@
 """
 Binds the python setuptools module as a rez package.
 """
-from __future__ import absolute_import
 from rez.bind import _pymodule
 
 
diff --git a/src/rez/bind/sip.py b/src/rez/bind/sip.py
index 9e1015e38..980ba51c2 100644
--- a/src/rez/bind/sip.py
+++ b/src/rez/bind/sip.py
@@ -5,7 +5,6 @@
 """
 Binds the python PyQt module as a rez package.
 """
-from __future__ import absolute_import
 from rez.bind import _pymodule
 from rez.bind._utils import get_version_in_python
 
diff --git a/src/rez/build_process.py b/src/rez/build_process.py
index 42f8fb9ed..c2e006b70 100644
--- a/src/rez/build_process.py
+++ b/src/rez/build_process.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.packages import iter_packages
 from rez.exceptions import BuildProcessError, BuildContextResolveError, \
     ReleaseHookCancellingError, RezError, ReleaseError, BuildError, \
diff --git a/src/rez/cli/_main.py b/src/rez/cli/_main.py
index a27de793a..a5a9744f0 100644
--- a/src/rez/cli/_main.py
+++ b/src/rez/cli/_main.py
@@ -5,8 +5,6 @@
 """
 The main command-line entry point.
 """
-from __future__ import print_function
-
 import sys
 import importlib
 from argparse import _StoreTrueAction, SUPPRESS
diff --git a/src/rez/cli/_util.py b/src/rez/cli/_util.py
index d398c7768..917c27777 100644
--- a/src/rez/cli/_util.py
+++ b/src/rez/cli/_util.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 import os
 import sys
 import signal
diff --git a/src/rez/cli/benchmark.py b/src/rez/cli/benchmark.py
index d2f1bfbcf..a3a568dd6 100644
--- a/src/rez/cli/benchmark.py
+++ b/src/rez/cli/benchmark.py
@@ -5,8 +5,6 @@
 '''
 Run a benchmarking suite for runtime resolves.
 '''
-from __future__ import print_function
-
 import json
 import os
 import os.path
diff --git a/src/rez/cli/bind.py b/src/rez/cli/bind.py
index 7aca03742..a8fc5d13d 100644
--- a/src/rez/cli/bind.py
+++ b/src/rez/cli/bind.py
@@ -5,8 +5,6 @@
 '''
 Create a Rez package for existing software.
 '''
-from __future__ import print_function
-
 import argparse
 
 
diff --git a/src/rez/cli/build.py b/src/rez/cli/build.py
index d70495a6d..208bab9a5 100644
--- a/src/rez/cli/build.py
+++ b/src/rez/cli/build.py
@@ -5,8 +5,6 @@
 '''
 Build a package from source.
 '''
-from __future__ import print_function
-
 import os
 
 
diff --git a/src/rez/cli/bundle.py b/src/rez/cli/bundle.py
index 39e862841..962c3ab01 100644
--- a/src/rez/cli/bundle.py
+++ b/src/rez/cli/bundle.py
@@ -5,8 +5,6 @@
 '''
 Bundle a context and its packages into a relocatable dir.
 '''
-from __future__ import print_function
-
 import os
 import os.path
 import sys
diff --git a/src/rez/cli/complete.py b/src/rez/cli/complete.py
index 98ffd4c45..7553866fa 100644
--- a/src/rez/cli/complete.py
+++ b/src/rez/cli/complete.py
@@ -5,8 +5,6 @@
 """
 Prints package completion strings.
 """
-from __future__ import print_function
-
 import argparse
 
 
diff --git a/src/rez/cli/config.py b/src/rez/cli/config.py
index 7f7b62986..c04ce1008 100644
--- a/src/rez/cli/config.py
+++ b/src/rez/cli/config.py
@@ -5,8 +5,6 @@
 '''
 Print current rez settings.
 '''
-from __future__ import print_function
-
 import json
 
 
diff --git a/src/rez/cli/context.py b/src/rez/cli/context.py
index 7d8de2bdb..b549c7a9a 100644
--- a/src/rez/cli/context.py
+++ b/src/rez/cli/context.py
@@ -5,8 +5,6 @@
 '''
 Print information about the current rez context, or a given context file.
 '''
-from __future__ import print_function
-
 # Disable the following:
 # - context tracking
 # - package caching
diff --git a/src/rez/cli/cp.py b/src/rez/cli/cp.py
index 7a297c6db..7b9c14231 100644
--- a/src/rez/cli/cp.py
+++ b/src/rez/cli/cp.py
@@ -5,7 +5,6 @@
 '''
 Copy a package from one repository to another.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/depends.py b/src/rez/cli/depends.py
index 166487e65..40eb00263 100644
--- a/src/rez/cli/depends.py
+++ b/src/rez/cli/depends.py
@@ -5,7 +5,6 @@
 """
 Perform a reverse package dependency lookup.
 """
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/env.py b/src/rez/cli/env.py
index 7b3d9c964..20cf68edf 100644
--- a/src/rez/cli/env.py
+++ b/src/rez/cli/env.py
@@ -5,7 +5,6 @@
 '''
 Open a rez-configured shell, possibly interactive.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/help.py b/src/rez/cli/help.py
index 6421e287f..cc1c9771e 100644
--- a/src/rez/cli/help.py
+++ b/src/rez/cli/help.py
@@ -5,7 +5,6 @@
 """
 Utility for displaying help for the given package.
 """
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/interpret.py b/src/rez/cli/interpret.py
index f4302de37..6c3f4a4d1 100644
--- a/src/rez/cli/interpret.py
+++ b/src/rez/cli/interpret.py
@@ -5,7 +5,6 @@
 '''
 Execute some Rex code and print the interpreted result.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/memcache.py b/src/rez/cli/memcache.py
index 42b20cd79..961e2fe6e 100644
--- a/src/rez/cli/memcache.py
+++ b/src/rez/cli/memcache.py
@@ -5,7 +5,6 @@
 """
 Manage and query memcache server(s).
 """
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/mv.py b/src/rez/cli/mv.py
index e02688296..803c6f280 100644
--- a/src/rez/cli/mv.py
+++ b/src/rez/cli/mv.py
@@ -5,7 +5,6 @@
 '''
 Move a package from one repository to another.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/pip.py b/src/rez/cli/pip.py
index a91bee8a8..f7f916b97 100644
--- a/src/rez/cli/pip.py
+++ b/src/rez/cli/pip.py
@@ -5,7 +5,6 @@
 """
 Install a pip-compatible python package, and its dependencies, as rez packages.
 """
-from __future__ import print_function
 from argparse import REMAINDER
 import logging
 
diff --git a/src/rez/cli/pkg-cache.py b/src/rez/cli/pkg-cache.py
index 26a62e871..367b7a0af 100644
--- a/src/rez/cli/pkg-cache.py
+++ b/src/rez/cli/pkg-cache.py
@@ -5,7 +5,6 @@
 '''
 Manipulate a package cache.
 '''
-from __future__ import print_function
 from argparse import SUPPRESS
 import os.path
 import sys
diff --git a/src/rez/cli/pkg-ignore.py b/src/rez/cli/pkg-ignore.py
index 557b1ca67..0b3dd8261 100644
--- a/src/rez/cli/pkg-ignore.py
+++ b/src/rez/cli/pkg-ignore.py
@@ -5,7 +5,6 @@
 '''
 Disable a package so it is hidden from resolves.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/plugins.py b/src/rez/cli/plugins.py
index 93e8265d2..4e26bbd7b 100644
--- a/src/rez/cli/plugins.py
+++ b/src/rez/cli/plugins.py
@@ -5,7 +5,6 @@
 """
 Get a list of a package's plugins.
 """
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/release.py b/src/rez/cli/release.py
index 870fe8b41..275f597ac 100644
--- a/src/rez/cli/release.py
+++ b/src/rez/cli/release.py
@@ -5,8 +5,6 @@
 '''
 Build a package from source and deploy it.
 '''
-from __future__ import print_function
-
 import os
 import sys
 from subprocess import call
diff --git a/src/rez/cli/rm.py b/src/rez/cli/rm.py
index 664152437..6433f0d57 100644
--- a/src/rez/cli/rm.py
+++ b/src/rez/cli/rm.py
@@ -5,7 +5,6 @@
 '''
 Remove package(s) from a repository.
 '''
-from __future__ import print_function
 import sys
 
 
diff --git a/src/rez/cli/search.py b/src/rez/cli/search.py
index e5d7bf8a4..a0a180d3d 100644
--- a/src/rez/cli/search.py
+++ b/src/rez/cli/search.py
@@ -5,8 +5,6 @@
 """
 Search for packages
 """
-from __future__ import print_function
-
 import os
 import sys
 
diff --git a/src/rez/cli/suite.py b/src/rez/cli/suite.py
index ece3a347a..02f34106b 100644
--- a/src/rez/cli/suite.py
+++ b/src/rez/cli/suite.py
@@ -5,7 +5,6 @@
 '''
 Manage a suite or print information about an existing suite.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/view.py b/src/rez/cli/view.py
index 4b639fb01..6e3cd5804 100644
--- a/src/rez/cli/view.py
+++ b/src/rez/cli/view.py
@@ -5,7 +5,6 @@
 """
 View the contents of a package.
 """
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/cli/yaml2py.py b/src/rez/cli/yaml2py.py
index 9aa958caa..66ee206ee 100644
--- a/src/rez/cli/yaml2py.py
+++ b/src/rez/cli/yaml2py.py
@@ -5,7 +5,6 @@
 """
 Print a package.yaml file in package.py format.
 """
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/config.py b/src/rez/config.py
index ae9e267dc..fe5fb2c89 100644
--- a/src/rez/config.py
+++ b/src/rez/config.py
@@ -2,7 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import absolute_import
 from rez import __version__
 from rez.utils.data_utils import AttrDictWrapper, RO_AttrDictWrapper, \
     convert_dicts, cached_property, cached_class_property, LazyAttributeMeta, \
diff --git a/src/rez/package_bind.py b/src/rez/package_bind.py
index d50b1c828..be51c1a52 100644
--- a/src/rez/package_bind.py
+++ b/src/rez/package_bind.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.exceptions import RezBindError, _NeverError
 from rez import module_root_path
 from rez.util import get_close_pkgs
diff --git a/src/rez/package_help.py b/src/rez/package_help.py
index 21411721f..b036dd1ca 100644
--- a/src/rez/package_help.py
+++ b/src/rez/package_help.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.packages import iter_packages
 from rez.config import config
 from rez.rex_bindings import VersionBinding
diff --git a/src/rez/package_serialise.py b/src/rez/package_serialise.py
index 5f905af43..c17b0c0ee 100644
--- a/src/rez/package_serialise.py
+++ b/src/rez/package_serialise.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.serialise import FileFormat
 from rez.package_resources import help_schema, late_bound
 from rez.vendor.schema.schema import Schema, Optional, And, Or, Use
diff --git a/src/rez/pip.py b/src/rez/pip.py
index f21f44b4a..b812ef12e 100644
--- a/src/rez/pip.py
+++ b/src/rez/pip.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function, absolute_import
-
 from rez.packages import get_latest_package
 from rez.version import Version
 from rez.vendor.distlib.database import DistributionPath
diff --git a/src/rez/resolved_context.py b/src/rez/resolved_context.py
index 349beadea..a20fcbdf8 100644
--- a/src/rez/resolved_context.py
+++ b/src/rez/resolved_context.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez import __version__, module_root_path
 from rez.package_repository import package_repository_manager
 from rez.solver import SolverCallbackReturn
diff --git a/src/rez/rex.py b/src/rez/rex.py
index 1f5d60888..520ce4a7b 100644
--- a/src/rez/rex.py
+++ b/src/rez/rex.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 import os
 import sys
 import re
diff --git a/src/rez/solver.py b/src/rez/solver.py
index 9990e6457..104296f99 100644
--- a/src/rez/solver.py
+++ b/src/rez/solver.py
@@ -11,8 +11,6 @@
 
 See SOLVER.md for an in-depth description of how this module works.
 """
-from __future__ import print_function
-
 from rez.config import config
 from rez.packages import iter_packages
 from rez.package_repository import package_repo_stats
diff --git a/src/rez/status.py b/src/rez/status.py
index 29949f16c..5be0b9d76 100644
--- a/src/rez/status.py
+++ b/src/rez/status.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 import sys
 import os
 import os.path
diff --git a/src/rez/suite.py b/src/rez/suite.py
index d12818847..7b84571e8 100644
--- a/src/rez/suite.py
+++ b/src/rez/suite.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.utils.execution import create_forwarding_script
 from rez.exceptions import SuiteError, ResolvedContextError
 from rez.resolved_context import ResolvedContext
diff --git a/src/rez/utils/colorize.py b/src/rez/utils/colorize.py
index 4fa3e8900..df0469662 100644
--- a/src/rez/utils/colorize.py
+++ b/src/rez/utils/colorize.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 import sys
 import logging
 from rez.vendor import colorama
diff --git a/src/rez/utils/diff_packages.py b/src/rez/utils/diff_packages.py
index 6c47192b8..6e949d00a 100644
--- a/src/rez/utils/diff_packages.py
+++ b/src/rez/utils/diff_packages.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.packages import iter_packages
 from rez.config import config
 from rez.plugin_managers import plugin_manager
diff --git a/src/rez/utils/filesystem.py b/src/rez/utils/filesystem.py
index 568ca6b9d..eb825f972 100644
--- a/src/rez/utils/filesystem.py
+++ b/src/rez/utils/filesystem.py
@@ -5,8 +5,6 @@
 """
 Filesystem-related utilities.
 """
-from __future__ import print_function
-
 from threading import Lock
 from tempfile import mkdtemp
 from contextlib import contextmanager
diff --git a/src/rez/utils/formatting.py b/src/rez/utils/formatting.py
index 9c542339d..89f255c84 100644
--- a/src/rez/utils/formatting.py
+++ b/src/rez/utils/formatting.py
@@ -5,8 +5,6 @@
 """
 Utilities related to formatting output or translating input.
 """
-from __future__ import absolute_import
-
 from string import Formatter
 from rez.vendor.enum import Enum
 from rez.version import Requirement
diff --git a/src/rez/utils/graph_utils.py b/src/rez/utils/graph_utils.py
index 8ff9c902b..0e040b8a1 100644
--- a/src/rez/utils/graph_utils.py
+++ b/src/rez/utils/graph_utils.py
@@ -5,8 +5,6 @@
 """
 Functions for manipulating dot-based resolve graphs.
 """
-from __future__ import print_function
-
 import os.path
 import sys
 import tempfile
diff --git a/src/rez/utils/installer.py b/src/rez/utils/installer.py
index e1931a5fc..c09503c12 100644
--- a/src/rez/utils/installer.py
+++ b/src/rez/utils/installer.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 import rez
 from rez.package_maker import make_package
 from rez.system import system
diff --git a/src/rez/utils/json.py b/src/rez/utils/json.py
index 26532e187..079260df1 100644
--- a/src/rez/utils/json.py
+++ b/src/rez/utils/json.py
@@ -2,7 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import absolute_import
 import json
 from json import dumps  # noqa (forwarded)
 import sys
diff --git a/src/rez/utils/logging_.py b/src/rez/utils/logging_.py
index 201305393..63a33e131 100644
--- a/src/rez/utils/logging_.py
+++ b/src/rez/utils/logging_.py
@@ -2,7 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
 from contextlib import contextmanager
 import logging
 import time
diff --git a/src/rez/utils/memcached.py b/src/rez/utils/memcached.py
index 4f27b183b..ab0945cc9 100644
--- a/src/rez/utils/memcached.py
+++ b/src/rez/utils/memcached.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.config import config
 from rez.vendor.memcache.memcache import Client as Client_, \
     SERVER_MAX_KEY_LENGTH, __version__ as memcache_client_version
diff --git a/src/rez/utils/py_dist.py b/src/rez/utils/py_dist.py
index 4bdc0e909..c8a96dcaa 100644
--- a/src/rez/utils/py_dist.py
+++ b/src/rez/utils/py_dist.py
@@ -5,8 +5,6 @@
 """
 Functions for converting python distributions to rez packages.
 """
-from __future__ import print_function
-
 from rez.exceptions import RezSystemError
 import pkg_resources
 import shutil
diff --git a/src/rez/utils/scope.py b/src/rez/utils/scope.py
index b889b8a8f..fa694d198 100644
--- a/src/rez/utils/scope.py
+++ b/src/rez/utils/scope.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.utils.formatting import StringFormatMixin, StringFormatType
 from collections import UserDict
 import sys
diff --git a/src/rez/version/_version.py b/src/rez/version/_version.py
index 8658980a2..0dc702e54 100644
--- a/src/rez/version/_version.py
+++ b/src/rez/version/_version.py
@@ -2,7 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
 from rez.version._util import VersionError, ParseException, _Common, \
     dedup
 from bisect import bisect_left
diff --git a/src/rez/wrapper.py b/src/rez/wrapper.py
index 638297700..8cf0b1f6b 100644
--- a/src/rez/wrapper.py
+++ b/src/rez/wrapper.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from rez.resolved_context import ResolvedContext
 from rez.utils.colorize import heading, local, critical, Printer
 from rez.utils.data_utils import cached_property
diff --git a/src/rezgui/dialogs/ProcessDialog.py b/src/rezgui/dialogs/ProcessDialog.py
index 8dd690ce8..b97ef5177 100644
--- a/src/rezgui/dialogs/ProcessDialog.py
+++ b/src/rezgui/dialogs/ProcessDialog.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from Qt import QtCore, QtWidgets
 from rezgui.util import create_pane
 from rezgui.mixins.StoreSizeMixin import StoreSizeMixin
diff --git a/src/rezgui/objects/ResolveThread.py b/src/rezgui/objects/ResolveThread.py
index 2d94518af..f600e4eb2 100644
--- a/src/rezgui/objects/ResolveThread.py
+++ b/src/rezgui/objects/ResolveThread.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 from Qt import QtCore
 from rez.exceptions import RezError
 
diff --git a/src/rezplugins/build_system/cmake.py b/src/rezplugins/build_system/cmake.py
index fdcb55035..6a76d92de 100644
--- a/src/rezplugins/build_system/cmake.py
+++ b/src/rezplugins/build_system/cmake.py
@@ -5,8 +5,6 @@
 """
 CMake-based build system
 """
-from __future__ import print_function
-
 from rez.build_system import BuildSystem
 from rez.build_process import BuildType
 from rez.resolved_context import ResolvedContext
diff --git a/src/rezplugins/release_hook/amqp.py b/src/rezplugins/release_hook/amqp.py
index e0fb860f9..cb3cefc3f 100644
--- a/src/rezplugins/release_hook/amqp.py
+++ b/src/rezplugins/release_hook/amqp.py
@@ -5,8 +5,6 @@
 """
 Publishes a message to the broker.
 """
-from __future__ import print_function
-
 from rez.release_hook import ReleaseHook
 from rez.utils.logging_ import print_error, print_debug
 from rez.utils.amqp import publish_message
diff --git a/src/rezplugins/release_hook/command.py b/src/rezplugins/release_hook/command.py
index 6b2e45731..eca4c1c18 100644
--- a/src/rezplugins/release_hook/command.py
+++ b/src/rezplugins/release_hook/command.py
@@ -5,8 +5,6 @@
 """
 Executes pre- and post-release shell commands
 """
-from __future__ import print_function
-
 import getpass
 import sys
 import os
diff --git a/src/rezplugins/release_hook/emailer.py b/src/rezplugins/release_hook/emailer.py
index e390fcd26..781151470 100644
--- a/src/rezplugins/release_hook/emailer.py
+++ b/src/rezplugins/release_hook/emailer.py
@@ -5,8 +5,6 @@
 """
 Sends a post-release email
 """
-from __future__ import print_function
-
 from rez.release_hook import ReleaseHook
 from rez.system import system
 from email.mime.text import MIMEText
diff --git a/src/rezplugins/release_vcs/git.py b/src/rezplugins/release_vcs/git.py
index 7048b0028..5aa1a59f4 100644
--- a/src/rezplugins/release_vcs/git.py
+++ b/src/rezplugins/release_vcs/git.py
@@ -5,8 +5,6 @@
 """
 Git version control
 """
-from __future__ import print_function
-
 from rez.release_vcs import ReleaseVCS
 from rez.utils.logging_ import print_error, print_debug
 from rez.exceptions import ReleaseVCSError
diff --git a/src/rezplugins/release_vcs/hg.py b/src/rezplugins/release_vcs/hg.py
index 13b8d08f7..ecdcb73c2 100644
--- a/src/rezplugins/release_vcs/hg.py
+++ b/src/rezplugins/release_vcs/hg.py
@@ -5,8 +5,6 @@
 """
 Mercurial version control
 """
-from __future__ import print_function
-
 from rez.release_vcs import ReleaseVCS
 from rez.exceptions import ReleaseVCSError
 from rez.utils.logging_ import print_debug, print_error
diff --git a/src/rezplugins/release_vcs/stub.py b/src/rezplugins/release_vcs/stub.py
index 9a5d64480..41029e527 100644
--- a/src/rezplugins/release_vcs/stub.py
+++ b/src/rezplugins/release_vcs/stub.py
@@ -5,8 +5,6 @@
 """
 Stub version control system, for testing purposes
 """
-from __future__ import print_function
-
 from rez.release_vcs import ReleaseVCS
 from rez.utils.logging_ import print_warning
 from rez.utils.yaml import dump_yaml
diff --git a/src/rezplugins/release_vcs/svn.py b/src/rezplugins/release_vcs/svn.py
index 05beb81ca..df1ab7337 100644
--- a/src/rezplugins/release_vcs/svn.py
+++ b/src/rezplugins/release_vcs/svn.py
@@ -5,8 +5,6 @@
 """
 Svn version control
 """
-from __future__ import print_function
-
 from rez.release_vcs import ReleaseVCS
 from rez.exceptions import ReleaseVCSError
 import os.path


Test patch:
diff --git a/src/rez/cli/test.py b/src/rez/cli/test.py
index b92e967f7..338269a0b 100644
--- a/src/rez/cli/test.py
+++ b/src/rez/cli/test.py
@@ -5,7 +5,6 @@
 '''
 Run tests listed in a package's definition file.
 '''
-from __future__ import print_function
 
 
 def setup_parser(parser, completions=False):
diff --git a/src/rez/data/tests/builds/packages/anti/1.0.0/build.py b/src/rez/data/tests/builds/packages/anti/1.0.0/build.py
index 0bffaa1ea..c636b5cff 100644
--- a/src/rez/data/tests/builds/packages/anti/1.0.0/build.py
+++ b/src/rez/data/tests/builds/packages/anti/1.0.0/build.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 from build_util import build_directory_recurse, check_visible
 
 def build(source_path, build_path, install_path, targets):
diff --git a/src/rez/data/tests/builds/packages/bah/2.1/build.py b/src/rez/data/tests/builds/packages/bah/2.1/build.py
index ef57ca999..56cabebc4 100644
--- a/src/rez/data/tests/builds/packages/bah/2.1/build.py
+++ b/src/rez/data/tests/builds/packages/bah/2.1/build.py
@@ -1,4 +1,3 @@
-from __future__ import print_function
 import os
 
 from build_util import build_directory_recurse, check_visible
diff --git a/src/rez/data/tests/builds/packages/build_util/1/build.py b/src/rez/data/tests/builds/packages/build_util/1/build.py
index d64a1e1e5..0d51f61eb 100644
--- a/src/rez/data/tests/builds/packages/build_util/1/build.py
+++ b/src/rez/data/tests/builds/packages/build_util/1/build.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 import shutil
 import os.path
 
diff --git a/src/rez/data/tests/builds/packages/build_util/1/build_util/__init__.py b/src/rez/data/tests/builds/packages/build_util/1/build_util/__init__.py
index 6a630e625..a516190d6 100644
--- a/src/rez/data/tests/builds/packages/build_util/1/build_util/__init__.py
+++ b/src/rez/data/tests/builds/packages/build_util/1/build_util/__init__.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 import shutil
 import os.path
 
diff --git a/src/rez/data/tests/builds/packages/foo/1.0.0/build.py b/src/rez/data/tests/builds/packages/foo/1.0.0/build.py
index 6b4ffa5b8..8ec96549f 100644
--- a/src/rez/data/tests/builds/packages/foo/1.0.0/build.py
+++ b/src/rez/data/tests/builds/packages/foo/1.0.0/build.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 from build_util import build_directory_recurse, check_visible
 import os.path
 import os
diff --git a/src/rez/data/tests/builds/packages/foo/1.1.0/build.py b/src/rez/data/tests/builds/packages/foo/1.1.0/build.py
index 9503672aa..93981be70 100644
--- a/src/rez/data/tests/builds/packages/foo/1.1.0/build.py
+++ b/src/rez/data/tests/builds/packages/foo/1.1.0/build.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 from build_util import build_directory_recurse, check_visible
 import os.path
 
diff --git a/src/rez/data/tests/release/build.py b/src/rez/data/tests/release/build.py
index 45c09877f..966915c98 100644
--- a/src/rez/data/tests/release/build.py
+++ b/src/rez/data/tests/release/build.py
@@ -1,5 +1,3 @@
-from __future__ import print_function
-
 import shutil
 import os.path
 import os
diff --git a/src/rez/tests/test_shells.py b/src/rez/tests/test_shells.py
index 736762286..35f7de76e 100644
--- a/src/rez/tests/test_shells.py
+++ b/src/rez/tests/test_shells.py
@@ -5,8 +5,6 @@
 """
 test shell invocation
 """
-from __future__ import print_function
-
 from rez.system import system
 from rez.shells import create_shell, get_shell_types, get_shell_class
 from rez.resolved_context import ResolvedContext
diff --git a/src/rez/tests/test_solver.py b/src/rez/tests/test_solver.py
index 1244dede5..4c9d44266 100644
--- a/src/rez/tests/test_solver.py
+++ b/src/rez/tests/test_solver.py
@@ -5,8 +5,6 @@
 """
 test dependency resolving algorithm
 """
-from __future__ import print_function
-
 import rez.exceptions
 from rez.version import Requirement
 from rez.solver import Solver, Cycle, SolverStatus
diff --git a/src/rez/tests/util.py b/src/rez/tests/util.py
index 865cd8ec9..dc03c9aa9 100644
--- a/src/rez/tests/util.py
+++ b/src/rez/tests/util.py
@@ -2,8 +2,6 @@
 # Copyright Contributors to the Rez Project
 
 
-from __future__ import print_function
-
 import unittest
 from rez import module_root_path
 from rez.config import config, _create_locked_config