aboutsummaryrefslogtreecommitdiffstats
path: root/testing/wheel_tester.py
diff options
context:
space:
mode:
authorChristian Tismer <tismer@stackless.com>2020-11-02 12:50:00 +0100
committerChristian Tismer <tismer@stackless.com>2020-11-02 13:26:38 +0000
commit6e3e7b9ca0548430aaa5e2555d6e02c64625fa3f (patch)
treea821c90747c2376d1396a4bf58330f8b41ccbaad /testing/wheel_tester.py
parent4544a943ca2df4e6f0ac24914f0c0f844dc6f748 (diff)
replace **locals by f-strings where possible
This change affects mostly only my own sources which were prepared for the migration to Python 3.6 . Task-number: PYSIDE-904 Change-Id: I0c2cd59f6f625f51f876099c33005ac70ca39db9 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io>
Diffstat (limited to 'testing/wheel_tester.py')
-rw-r--r--testing/wheel_tester.py19
1 files changed, 9 insertions, 10 deletions
diff --git a/testing/wheel_tester.py b/testing/wheel_tester.py
index 4339d7e95..e911913da 100644
--- a/testing/wheel_tester.py
+++ b/testing/wheel_tester.py
@@ -150,18 +150,17 @@ def try_install_wheels(wheels_dir, py_version):
log.info("")
for p in package_prefix_names():
- log.info("Trying to install {p}:".format(**locals()))
+ log.info(f"Trying to install {p}:")
pattern = "{}-*cp{}*.whl".format(p, int(float(py_version)))
files = find_files_using_glob(wheels_dir, pattern)
if files and len(files) == 1:
wheel_path = files[0]
install_wheel(wheel_path)
elif len(files) > 1:
- raise RuntimeError("More than one wheel found for specific {p} version."
- .format(**locals()))
+ raise RuntimeError(f"More than one wheel found for specific {p} version.")
else:
- raise RuntimeError("No {p} wheels compatible with Python {py_version} found "
- "for testing.".format(**locals()))
+ raise RuntimeError(f"No {p} wheels compatible with Python {py_version} found "
+ f"for testing.")
def is_unix():
@@ -200,13 +199,13 @@ def generate_build_qmake():
def raise_error_pyinstaller(msg):
print()
- print("PYINST: {msg}".format(**locals()))
- print("PYINST: sys.version = {}".format(sys.version.splitlines()[0]))
- print("PYINST: platform.platform() = {}".format(platform.platform()))
- print("PYINST: See the error message above.")
+ print(f"PYINST: {msg}")
+ print(f"PYINST: sys.version = {sys.version.splitlines()[0]}")
+ print(f"PYINST: platform.platform() = {platform.platform()}")
+ print(f"PYINST: See the error message above.")
print()
for line in run_process_output([sys.executable, "-m", "pip", "list"]):
- print("PyInstaller pip list: ", line)
+ print(f"PyInstaller pip list: {line}")
print()
raise(RuntimeError(msg))