Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
apks/chromium/default.nix: Fix a Python version incompatibility
Fixes e.g.: python3 ../../tools/grit/grit.py -i ../../chrome/app/generated_resources.grd build -o gen/chrome --depdir . --depfile gen/chrome/app/generated_resources_grit.d --write-only-new=1 --depend-on-stamp -E root_gen_dir=gen -E root_src_dir=../../ -D SHARED_INTERMEDIATE_DIR=gen -D DEVTOOLS_GRD_PATH=gen/third_party/devtools-frontend/src/front_end/devtools_resources -D _chromium -E CHROMIUM_BUILD=chromium -E ANDROID_JAVA_TAGGED_ONLY=true -t android -D enable_arcore=false -D enable_background_mode=false -D enable_background_contents=false -D enable_extensions=false -D enable_hangout_services_extension=false -D enable_plugins=false -D enable_print_preview=false -D enable_printing=true -D enable_service_discovery=false -D enable_side_search=false -D enable_supervised_users=true -D enable_vr=false -D enable_webui_tab_strip=false -D safe_browsing_mode=2 -D optimize_webui=true -D enable_feed_v2=true -D use_nss_certs=false -f gen/tools/gritsettings/default_resource_ids --assert-file-list obj/chrome/app/generated_resources_expected_outputs.txt --allowlist-support --js-minifier ../../tools/grit/minify_with_uglify.py --css-minifier ../../tools/grit/minimize_css.py Traceback (most recent call last): File "/build/chromium-100.0.4896.127-src/src/out/Release/../../tools/grit/grit.py", line 29, in <module> sys.exit(grit.grit_runner.Main(sys.argv[1:])) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/build/chromium-100.0.4896.127-src/src/tools/grit/grit/grit_runner.py", line 314, in Main return toolobject.Run(options, args[1:]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/build/chromium-100.0.4896.127-src/src/tools/grit/grit/tool/build.py", line 255, in Run self.res = grd_reader.Parse(opts.input, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/build/chromium-100.0.4896.127-src/src/tools/grit/grit/grd_reader.py", line 231, in Parse handler.root.AssignFirstIds(filename_or_stream, defines) File "/build/chromium-100.0.4896.127-src/src/tools/grit/grit/node/misc.py", line 611, in AssignFirstIds src_root_dir, first_ids = _ReadFirstIdsFromFile(first_ids_filename, ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/build/chromium-100.0.4896.127-src/src/tools/grit/grit/node/misc.py", line 67, in _ReadFirstIdsFromFile first_ids_dict = eval(util.ReadFile(filename, 'utf-8')) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/build/chromium-100.0.4896.127-src/src/tools/grit/grit/util.py", line 214, in ReadFile with io.open(filename, mode, encoding=encoding) as f: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ValueError: invalid mode: 'rU' Unfortunately, it is not enough to allow chromium to build, but it does fix that particular error.
- Loading branch information