-
-
Notifications
You must be signed in to change notification settings - Fork 9.8k
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
pyenv does not work with brew pyenv-sync
#17563
Comments
I'm not sure how this ever worked unless the layout of the python formulae or the behavior of
The other links are present, but only under |
I'm seeing the same behavior (no "python" command available, only "python3"). But I'm also seeing the that "pyenv local", "pyenv shell", and even pipenv doesn't work with any version of python linked/synced from brew; only versions installed by pyenv |
Yep.
Note that there is no overlap in these lists (i.e. no |
Exactly that. Note that Homebrew is not a version manager. The only reason versioned formulae exist is because other formulae don't work with the newest version. |
Indeed, something may have changed. I have noticed ~/.pyenv/bin does not get created (unless For the time being I have just resolved to use pyenv with redundancy. Inspecting again, I can see ~ % ls ~/.pyenv/versions
3.10.14 3.11.9 3.12.4 ~ % ls ~/.pyenv/versions/3.12.4
bin include lib share ~ % ls ~/.pyenv/versions/3.12.4/bin
2to3 idle3.12 pydoc python-config python3.12-config
2to3-3.12 pip pydoc3 python3 python3.12-gdb.py
idle pip3 pydoc3.12 python3-config
idle3 pip3.12 python python3.12 @rrotter Now I understand your comment
~ % /opt/homebrew/Cellar/[email protected]/3.12.4
Frameworks LICENSE bin sbom.spdx.json
IDLE 3.app Python Launcher 3.app lib share
INSTALL_RECEIPT.json README.rst libexec ~ % ls /opt/homebrew/Cellar/[email protected]/3.12.4/bin
2to3 idle3.12 pydoc3 python3-config wheel3
2to3-3.12 pip3 pydoc3.12 python3.12 wheel3.12
idle3 pip3.12 python3 python3.12-config I would like to start playing with authoring/modifying homebrew formulaes, but do not have the time now (until September). In [email protected] formulae
Possibly off topic, but providing context: I have seen people both
I was leaning towards 1. as I want ideally one place to think about installing/uninstalling software, but I was seeking automation and @reitermarkus I see your point, if you are fine with latest minor releases use homebrew, if you need something more specific go elsewhere (e.g. pyenv/virtualenv/conda/docker). |
This seems like a good idea and the best implementation here. |
Ran into the same issue and created a PR to resolve this: |
brew doctor
outputVerification
brew doctor
output" above saysYour system is ready to brew.
and am still able to reproduce my issue.brew update
twice and am still able to reproduce my issue.brew install wget
. If they do, open an issue at https://github.com/Homebrew/homebrew-core/issues/new/choose instead.brew config
outputWhat were you trying to do (and why)?
brew pyenv-sync
I am trying to use brew-installed python distributions using pyenv.
What happened (include all command output)?
but when I execute
python
orpyenv which python
I getI see the symlinks:
ls ~/.pyenv/versions 3.10.0 3.10.11 3.10.14 3.10.4 3.10.7 3.11.0 3.11.3 3.11.6 3.11.9 3.12.2 3.10.1 3.10.12 3.10.2 3.10.5 3.10.8 3.11.1 3.11.4 3.11.7 3.12.0 3.12.3
Then I see
This is happening both when using a
.python-version
file viapyenv local 3.10
as well as for the global optionpyenv global 3.10
As you can see, the correct python version is selected as denoted by the asterisk.
What did you expect to happen?
I expected that pyenv would select and appropriate pyhton version (brew-installed) and carry on.
This is relevant? /orgs/Homebrew/discussions/4664
Step-by-step reproduction instructions (by running
brew
commands)brew install [email protected]
brew install pyenv
pyenv --init makes me put this in path, I have updated it with the shims and put it into my
~/.zshrc
>>> pyenv init >>>
export PYENV_ROOT="$HOME/.pyenv"
[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"
[[ -d $PYENV_ROOT/shims ]] && export PATH="$PYENV_ROOT/shims:$PATH"
eval "$(pyenv init -)"
<<< pyenv init <<<<
source ~/.zshrc
pyenv which python; python --version
The text was updated successfully, but these errors were encountered: