View previous topic :: View next topic |
Author |
Message |
CaptainBlood Advocate
Joined: 24 Jan 2010 Posts: 3675
|
Posted: Sat May 25, 2024 3:25 pm Post subject: app-admin/ansible & /usr/bin/python issue here |
|
|
pyrhon-3.[10,11,12].
default is 3.11
ansible is installed for 3.11
However, calling ansible here warns: Code: | [WARNING]: Platform linux on host node1 is using the discovered Python
interpreter at /usr/bin/python3.12, but future installation of another Python
interpreter could change the meaning of that path. See
https://docs.ansible.com/ansible-
core/2.16/reference_appendices/interpreter_discovery.html for more information. |
The only workaround found here is to define ansible_python_interpreter=/usr/bin/python3.11.
This inhibits the previous warning.
So /usr/bin/python doesn't seem recognized.
Any experience to share?
Thks 4 ur attention, interest & support. _________________ USE="-* ..." in /etc/portage/make.conf here, i.e. a countermeasure to portage implicit braces, belt & diaper paradigm
LT: "I've been doing a passable imitation of the Fontana di Trevi, except my medium is mucus. Sooo much mucus. " |
|
Back to top |
|
|
freke Veteran
Joined: 23 Jan 2003 Posts: 1006 Location: Somewhere in Denmark
|
Posted: Sat May 25, 2024 4:41 pm Post subject: Re: app-admin/ansible & /usr/bin/python issue here |
|
|
CaptainBlood wrote: | pyrhon-3.[10,11,12].
default is 3.11
ansible is installed for 3.11
However, calling ansible here warns: Code: | [WARNING]: Platform linux on host node1 is using the discovered Python
interpreter at /usr/bin/python3.12, but future installation of another Python
interpreter could change the meaning of that path. See
https://docs.ansible.com/ansible-
core/2.16/reference_appendices/interpreter_discovery.html for more information. |
The only workaround found here is to define ansible_python_interpreter=/usr/bin/python3.11.
This inhibits the previous warning.
So /usr/bin/python doesn't seem recognized.
Any experience to share?
Thks 4 ur attention, interest & support. |
Reading https://docs.ansible.com/ansible-core/2.16/reference_appendices/interpreter_discovery.html values seems to should be Quote: | Use one of the following values:
auto_legacy :
Detects the target OS platform, distribution, and version, then consults a table listing the correct Python interpreter and path for each platform/distribution/version. If an entry is found, and /usr/bin/python is absent, uses the discovered interpreter (and path). If an entry is found, and /usr/bin/python is present, uses /usr/bin/python and issues a warning. This exception provides temporary compatibility with previous versions of Ansible that always defaulted to /usr/bin/python, so if you have installed Python and other dependencies at /usr/bin/python on some hosts, Ansible will find and use them with this setting. If no entry is found, or the listed Python is not present on the target host, searches a list of common Python interpreter paths and uses the first one found; also issues a warning that future installation of another Python interpreter could alter the one chosen.
auto(default in 2.12)
Detects the target OS platform, distribution, and version, then consults a table listing the correct Python interpreter and path for each platform/distribution/version. If an entry is found, uses the discovered interpreter. If no entry is found, or the listed Python is not present on the target host, searches a list of common Python interpreter paths and uses the first one found; also issues a warning that future installation of another Python interpreter could alter the one chosen.
auto_legacy_silent
Same as auto_legacy, but does not issue warnings.
auto_silent
Same as auto, but does not issue warnings. |
Here is running ansible for python3_12 and with Code: | ns ~ # python -V
Python 3.12.3 | Ansible does not produce any warning for me. |
|
Back to top |
|
|
CaptainBlood Advocate
Joined: 24 Jan 2010 Posts: 3675
|
Posted: Sat May 25, 2024 10:37 pm Post subject: |
|
|
Is 3.13 installed?
Thks 4 ur attention, interest & support. _________________ USE="-* ..." in /etc/portage/make.conf here, i.e. a countermeasure to portage implicit braces, belt & diaper paradigm
LT: "I've been doing a passable imitation of the Fontana di Trevi, except my medium is mucus. Sooo much mucus. " |
|
Back to top |
|
|
szatox Advocate
Joined: 27 Aug 2013 Posts: 3203
|
Posted: Sat May 25, 2024 11:05 pm Post subject: |
|
|
Does /usr/bin/python actually point to python3.11 on your system?
Anyway, it's a warning telling you that the interpreter in use is not set in stone AKA things that used to work might be broken now and things that work now might potentially break in the future without you explicitly taking an action to change the interpreter.
In practice it's not that big deal really... I think python is like 50 years old by now, it had a lot of time to mature, changes happen slowly,so things tend to work the same over multiple versions. You're not likely to encounter any problems because of that. _________________ Make Computing Fun Again |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 21918
|
Posted: Sat May 25, 2024 11:31 pm Post subject: |
|
|
szatox wrote: | I think python is like 50 years old by now, it had a lot of time to mature, changes happen slowly,so things tend to work the same over multiple versions. You're not likely to encounter any problems because of that. | Not quite 50 yet. Wikipedia points to an archive.org copy of a February 1991 posting as the first release, so about 33 years.
That said, other than the Python2 -> Python3 transition, which nobody wants to go through again, Python upgrades have indeed been very compatible. |
|
Back to top |
|
|
szatox Advocate
Joined: 27 Aug 2013 Posts: 3203
|
Posted: Sat May 25, 2024 11:47 pm Post subject: |
|
|
Damn... I though it started somewhere in 70's. Fortunately, in computers' time scale 90's it's still like antiquity, so my my point stands, even if it shook a little
I wonder which language I mixed it up with though... _________________ Make Computing Fun Again |
|
Back to top |
|
|
freke Veteran
Joined: 23 Jan 2003 Posts: 1006 Location: Somewhere in Denmark
|
Posted: Sun May 26, 2024 5:56 am Post subject: |
|
|
szatox wrote: | Damn... I though it started somewhere in 70's. Fortunately, in computers' time scale 90's it's still like antiquity, so my my point stands, even if it shook a little
I wonder which language I mixed it up with though... |
Pascal maybe? https://en.wikipedia.org/wiki/Pascal_(programming_language)
I remember that from my schooldays mid 80's |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|