Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

virtualenv forces the use of Python 3 #2

Open
oSoMoN opened this issue Jan 23, 2019 · 1 comment
Open

virtualenv forces the use of Python 3 #2

oSoMoN opened this issue Jan 23, 2019 · 1 comment

Comments

@oSoMoN
Copy link

oSoMoN commented Jan 23, 2019

I'm using snapcraft-pr to test the work on the gnome extension, and when rebuilding the chromium snap, I'm getting errors when the build system runs python 2 scripts, such as:

+ out/Release/gn gen out/Release
ERROR at //build/util/branding.gni:27:11: Script returned non-zero exit code.
_result = exec_script("version.py",
          ^----------
Current dir: /mnt/chromium/snap-from-source/parts/chromium/build/out/Release/
Command: python /mnt/chromium/snap-from-source/parts/chromium/build/build/util/version.py -f ../../chrome/app/theme/chromium/BRANDING -t full_name = "@PRODUCT_FULLNAME@" short_name = "@PRODUCT_SHORTNAME@" bundle_id = "@MAC_BUNDLE_ID@" creator_code = "@MAC_CREATOR_CODE@" installer_full_name = "@PRODUCT_INSTALLER_FULLNAME@" installer_short_name = "@PRODUCT_INSTALLER_SHORTNAME@" team_id = "@MAC_TEAM_ID@" 
Returned 1.
stderr:

  File "/mnt/chromium/snap-from-source/parts/chromium/build/build/util/version.py", line 71
    print repr(key), repr(val)
             ^
SyntaxError: invalid syntax

I'm guessing the virtualenv in which snapcraft-pr runs only exposes python3. Not sure whether that can be "fixed", input welcome.

@kyrofa
Copy link
Owner

kyrofa commented Feb 10, 2019

Yeah, I've run into this before, it seems impossible to create a venv for both python2 and 3 :( .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants