Assorted GPU Python 3 changes
Makes a number of assorted changes to the GPU code to make it more
Python 3-compatible. This includes, but is not limited to:
1. Improper use of empty "raise" statements
2. String vs. binary data issues
3. Use of removed class types such as "unicode"
4. Use of mock vs. unittest.mock
5. Use of iteritems vs. items
Issues were found via running the unittests in Python 3 and looking at
what VSCode's Pylance plugin complained about.
Also drive-by removes some unused imports since Pylance points those
out.
Bug: 1198237
Change-Id: I0f18494d473611e3131c597a21d379473cc9f3ff
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2891513
Commit-Queue: Brian Sheedy <[email protected]>
Auto-Submit: Brian Sheedy <[email protected]>
Reviewed-by: Robbie Iannucci <[email protected]>
Reviewed-by: Yuly Novikov <[email protected]>
Cr-Commit-Position: refs/heads/master@{#883222}
diff --git a/.vpython3 b/.vpython3
index c8c82fd..1f38037 100644
--- a/.vpython3
+++ b/.vpython3
@@ -39,6 +39,15 @@
>
# Common utilities.
+# For Python 2, this version needed to be compatible with the version range
+# specified by
+# //third_party/catapult/telemetry/telemetry/internal/util/external_modules.py
+# However, the hope is that Telemetry's Python 3 migration will fix this, so
+# use the newer version that's currently available in CIPD for now.
+wheel: <
+ name: "infra/python/wheels/numpy/${vpython_platform}"
+ version: "version:1.19.5"
+>
wheel: <
name: "infra/python/wheels/psutil/${vpython_platform}"
version: "version:5.7.2"
@@ -62,6 +71,11 @@
version: "version:3.0.0"
>
+wheel: <
+ name: "infra/python/wheels/pyfakefs-py2_py3"
+ version: "version:3.7.2"
+>
+
# Used by:
# build/chromeos/test_runner.py
wheel: <
@@ -202,8 +216,3 @@
name: "infra/python/wheels/atomicwrites-py2_py3"
version: "version:1.3.0"
>
-
-wheel: <
- name: "infra/python/wheels/pyfakefs-py2_py3"
- version: "version:3.7.2"
->