-
Notifications
You must be signed in to change notification settings - Fork 431
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, Failed to find python version #81
Comments
Hmm - the check to get the version from the filename is really supposed to be a last ditch measure, we should almost certainly be able to get it from the BSS section of the python binary. Can you enable logging and paste the output here ( |
I have similar problem with virtualenv on Ubuntu 18.10:
On other terminal:
|
I'm having the same issue on Windows 10 with Python 3.7.2. It works fine with 3.6.8 and 3.7.1. The big difference I can find in the logs is that for Python 3.6.8 I see
Creating a virtualenv for 3.7.2 with the For Windows this all is probably caused by python/cpython@1c3de54#diff-8721d1362294720bad1dbbbaa4cc06e3 tl;dr: EDIT: |
I have a (related?) problem on mac, with a self-built python and a version |
So - I think there are at least 2 different issues here:
|
If you build the branch while it's not released, it's showing the Thanks for the fix. |
Added a new issue to track profiling subprocess (#124). Closing this one. |
My apologies if this has been asked and answered before, I did look through open and closed issues but didn't see anything quite like it.
I'm trying to run py-spy v0.1.10 in a virtualenv on a Debian unstable system. I'm receiving an "Error: Failed to find python version from target process" message whenever I attempt to launch the profiler via
py-spy -- python2.7 my_script.py
. I enabled logging (RUST_LOG=info
) and saw that thepython2.7
is read by py-spy as/path/to/python2
, without its version number. Looking in the virtualenv's bin directory, I saw that there is apython2.7
symlinked topython2
. This is the opposite of my system's installed python, wherepython2
is symlinked topython2.7
.I see in
py-spy/src/python_spy.rs
Line 215 in 27d20df
/path/to/pythonN.M
and picking off theN.M
. Since the python executable presented to py-spy while the virtualenv is activated doesn't have this form, the version number detection fails.I'm able to work around this by using
virtualenv --always-copy venv_target_dir
, which doesn't generate symlinks in the virtualenv.The text was updated successfully, but these errors were encountered: