asdf
asdf copied to clipboard
bug: Although system Python version matches .tool-versions in a git repo, it is not picked up.
Describe the Bug
When a Python version matching the system version is not installed, asdf does not fallback to the system version and requests that the same version be installed with asdf install.
Steps to Reproduce
Make a .tool-versions that matches the system Python version in a directory:
hugo ~/src $ mkdir asdf-bug-roguh
hugo ~/src $ cd asdf-bug-roguh/
hugo ~/s/asdf-bug-roguh $ echo 'python 3.9.7' > .tool-versions
No preset version installed for command python3
Please install a version by running one of the following:
asdf install python 3.9.7
or add one of the following versions in your config file at /home/hugo/src/asdf-bug-roguh/.tool-versions
python 3.10-dev
python 3.11-dev
python 3.8.11
Observe that asdf does not detect the system Python version:
hugo ~ $ python
Python 3.9.7 (default, Aug 31 2021, 13:28:12)
[GCC 11.1.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>>
Expected Behaviour
asdf should use the system Python version if it matches a requirement in .tool-versions
Actual Behaviour
asdf complains that Python 3.9.7 is not installed, even though it is my system version
Environment
$ asdf-info
fish: Unknown command: asdf-info
$ inxi
CPU: Quad Core Intel Core i7-8650U (-MT MCP-)
speed/min/max: 900/400/4200 MHz Kernel: 5.9.16-1-MANJARO x86_64
Up: 10m Mem: 2924.9/23899.4 MiB (12.2%)
Storage: 1.82 TiB (8.7% used) Procs: 252 Shell: fish inxi: 3.3.07
$ uname -a
Linux Tezcatlipoca-T580 5.9.16-1-MANJARO #1 SMP PREEMPT Mon Dec 21 22:00:46 UTC 2020 x86_64 GNU/Linux
$ asdf --version
v0.8.1-a1ef92a
asdf plugins affected (if relevant)
Python plugin
Is this the same issue? https://github.com/asdf-vm/asdf/issues/1069
If I understand this correct, if no python version is set you would like asdf to fallback to the system version of python already installed by the OS?
That's correct, as long as the system version is the same that is required. #1069 is this issue
Sorry, I pasted the wrong link. Is this the same issue? https://github.com/asdf-vm/asdf/issues/557
This also appears to be the same issue - https://github.com/danhper/asdf-python/issues/85
Did someone find a workaround? :?