I have installed a specific version of Python and it shows when I run pyenv versions:
% pyenv versions
system
* 3.10.4 (set by .python-version)
However, when I try to use Python (in a venv or without), it always uses the system version instead of the specific version I want to use.
% python3 --version
Python 3.10.6
% python3 -m venv venv3-10-4
% . venv3-10-4/bin/activate
(venv3-10-4) % python3 --version
Python 3.10.6
How do I get my system to use 3.10.4 inside and outside the venv? I tried this, but it didn't help:
pyenv global 3.10.4
I tried setting the version inside the venv too:
(venv3-10-4) > % pyenv local 3.10.4
(venv3-10-4) > % python3 --version
Python 3.10.6