-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Broken activation in Windows for python3 #1710
Comments
it comes from here (it gets replaced):
it should probably be substituted as a boolean or |
actually no, it looks correct as written, that'll only be truthy in cpython2.x windows (assuming the constant is correct) |
ah, but the constant is for the host python, not the destination python |
Yeah so the thing is why is it "yes" when executing the above script using python3 ? |
in this case it's "yes" because you used a python2.x you can work around by using a python3.x |
well I'm using |
right, it's not about the python that executes that script, but the python that was used to create the virtualenv to be clear, there's a bug in virtualenv here -- but a workaround is to use the same python version when creating the virtualenv |
Ah yeah, I've just skimmed through the PATH variable in windows and it turns out that py2.7 is listed before than py3 so |
Just for reference I think I can workaround it by doing something like
and for the case of windows I guess I should concat |
Hello, a fix for this issue has been released via virtualenv 20.0.11; see https://pypi.org/project/virtualenv/20.0.11/ (https://virtualenv.pypa.io/en/latest/changelog.html#v20-0-11-2020-03-18). Please give a try and report back if your issue has not been addressed; if not, please comment here, and we'll reopen the ticket. We want to apologize for the inconvenience this has caused you and say thanks for having patience while we resolve the unexpected bugs with this new major release. |
Tests in test_wpt.py were marked as xfail due to virtualenv activation issue (pypa/virtualenv#1710) This issue has now been solved.
Tests in test_wpt.py were marked as xfail due to virtualenv activation issue (pypa/virtualenv#1710) This issue has now been solved.
… in PY3, a=testonly Automatic update from web-platform-tests Python3: Remove xfail for wpt unit tests in PY3 (#26202) Tests in test_wpt.py were marked as xfail due to virtualenv activation issue (pypa/virtualenv#1710) This issue has now been solved. -- wpt-commits: 35faa70dcf2889231814b97c6a04e6fee8916e0e wpt-pr: 26202
… in PY3, a=testonly Automatic update from web-platform-tests Python3: Remove xfail for wpt unit tests in PY3 (#26202) Tests in test_wpt.py were marked as xfail due to virtualenv activation issue (pypa/virtualenv#1710) This issue has now been solved. -- wpt-commits: 35faa70dcf2889231814b97c6a04e6fee8916e0e wpt-pr: 26202
virtualenv activation through
activate_this.py
is broken in Windows for python3. Check this very simple piece of codeThis generates a
AttributeError: 'str' object has no attribute 'decode'
. Taking a look at theactivate_this.py
code:it's indeed normal that we get the error because we're always calling
decode()
over a str. Question is where the__DECODE_PATH__
from https://github.com/pypa/virtualenv/blob/master/src/virtualenv/activation/python/activate_this.py#L28 is assigned to"yes"
?The text was updated successfully, but these errors were encountered: