To install and run python-modernize on Windows using Chromium’s version of python3 bundled with depot_tools:
# Install python3 -m pip install modernize # Run python3 -m modernize --no-six -w file.py
Python 2 is end-of-life and CEF scripts should be updated to work with both Python 2 and Python 3 (minimum version 3.4).
automate-git.py
with Python 3 will utilize Python 3 for as many build steps as possible (3945 branch and newer).For reference, see http://python-future.org/compatible_idioms.html, python-modernize and 2to3.
To install and run python-modernize on Windows using Chromium’s version of python3 bundled with depot_tools:
# Install python3 -m pip install modernize # Run python3 -m modernize --no-six -w file.py
cefbuilds: Add Python 3 support (see issue #2856)
→ <<cset 11ee7e984cdc>>
gn_args: Add Python 3 support (see issue #2856)
→ <<cset 503ec7c2e6a6>>
patcher: Add Python 3 support (see issue #2856)
→ <<cset 16e8710a8139>>
patch_updater: Add Python 3 support (see issue #2856)
→ <<cset 5792cea9859a>>
cef_version: Add Python 3 support (see issue #2856)
→ <<cset dbc479e4907a>>
translator: Add Python 3 support (see issue #2856)
This also fixes incorrect translation of types in capi header comments.
→ <<cset 1b85022c5880>>
Fix incorrectly translated types in capi header comments (see issue #2856)
→ <<cset 15226b933298>>
make_distrib: Add Python 3 support (see issue #2856)
→ <<cset e1132672eefd>>
Fix Python 2 TypeError: write() argument 1 must be unicode, not str (see issue #2856)
→ <<cset 894ac215326e>>
gclient_hook: Add Python 3 support (see issue #2856)
→ <<cset b98f142e0efa>>
build: Add Python 3 support (see issue #2856)
→ <<cset 3afa29d499b0>>
Use explicit check for python version (see issue #2856)
→ <<cset 1a406d079b65>>
gn_args: Fix Python 3 AttributeError: 'module' object has no attribute 'exc_clear' (see issue #2856)
→ <<cset 08f6cbb67526>>
gn_args: Fix representation of int-type GN_DEFINES values (see issue #2856)
→ <<cset 06a5a5bb36c3>>
cefbuilds: Add Python 3 support (see issue #2856)
→ <<cset 497033bd8af3>>
gn_args: Add Python 3 support (see issue #2856)
→ <<cset d2de1468d82e>>
patcher: Add Python 3 support (see issue #2856)
→ <<cset 70c5db44d128>>
patch_updater: Add Python 3 support (see issue #2856)
→ <<cset 5eeb26cb76b3>>
cef_version: Add Python 3 support (see issue #2856)
→ <<cset b06a408e7f00>>
translator: Add Python 3 support (see issue #2856)
This also fixes incorrect translation of types in capi header comments.
→ <<cset ca65ff02c43f>>
Fix incorrectly translated types in capi header comments (see issue #2856)
→ <<cset 29cbaf7e2198>>
make_distrib: Add Python 3 support (see issue #2856)
→ <<cset 716121c74a62>>
Fix Python 2 TypeError: write() argument 1 must be unicode, not str (see issue #2856)
→ <<cset 6dbe2b782f9f>>
gclient_hook: Add Python 3 support (see issue #2856)
→ <<cset f24e1caec960>>
build: Add Python 3 support (see issue #2856)
→ <<cset f527bf312c9b>>
Use explicit check for python version (see issue #2856)
→ <<cset cc2fc7eaffef>>
gn_args: Fix Python 3 AttributeError: 'module' object has no attribute 'exc_clear' (see issue #2856)
→ <<cset 71efeca3351d>>
gn_args: Fix representation of int-type GN_DEFINES values (see issue #2856)
→ <<cset 1dbdf7b9cbcd>>
crash_server: Add Python 3 support (see issue #2856)
→ <<cset f0347f05891d>>
fix_style: Add Python 3 support (see issue #2856)
→ <<cset 53b98a5022a2>>
crash_server: Add Python 3 support (see issue #2856)
→ <<cset cb2b46f6d7cc>>
fix_style: Add Python 3 support (see issue #2856)
→ <<cset 50b44dcfea07>>
All CEF scripts have now been updated for Python 3 support. The bat/sh scripts won’t be switched to Python 3 until Chromium has completely transitioned to Python 3, at which point there will be no remaining dependencies on Python 2.
Spotify build 79.1.24+g1dbdf7b+chromium-79.0.3945.117
and newer have been generated by running automate-git.py
with Python 3.
Fix tarfile issues by using GNU_FORMAT with Python 3.8 (see issue #2856)
→ <<cset c629c5bb593a>>
Fix tarfile issues by using GNU_FORMAT with Python 3.8 (see issue #2856)
→ <<cset d2449e563c3e>>
Python 3 support added to cef-project in https://bitbucket.org/chromiumembedded/cef-project/commits/d0104133.
Binary distributions built with Python 3 now appear correct as of version 79.1.27+gd2449e5+chromium-79.0.3945.117
.
All CEF scripts have now been updated for Python 3 support. The bat/sh scripts won’t be switched to Python 3 until Chromium has completely transitioned to Python 3, at which point there will be no remaining dependencies on Python 2.
Spotify build
79.1.24+g1dbdf7b+chromium-79.0.3945.117
and newer have been generated by runningautomate-git.py
with Python 3.