Talk:Python

From Gentoo Wiki
Jump to:navigation Jump to:search
Note
This is a talk page. Please add newer comments below older ones, and sign your comments using four tildes (~~~~). When adding a new section (at the bottom of the page), please mark it as "open for discussion" by using {{talk|open}} so it will show up in the list of open discussions.

Slotting questions

Talk status
This discussion is still ongoing.

'emerge --ask --depclean dev-lang/python' and 'eselect python cleanup' only deal the previous python version(such as python3.7). If I run 'emerge --ask --changed-use --deep @world', python 3.9 will be installed.

If I only want to install python3.8 not python3.9 or higher version. I need to add '>=dev-lang/python-3.9' to '/etc/portage/package.mask'. Is there any other way?

--Soymilk (talk) 13:56, 13 July 2020 (UTC)


Upgrading Python

Talk status
This discussion is done.

It is such a drag, this time again with the change from Python3.7 to Python3.8. So many conflicts. And then there are these mysterious two all controlling variables PYTHON_TARGETS and PYTHON_SINGLE_TARGET, which are never properly explained. You can set them in /etc/portage/make.conf, and/or in /etc/portage/package.use. And there are is different syntax for these as well. It would be so awesome if it was clearly explained what these variables do. Hfern (talk) 18:22, 12 December 2020 (UTC)

Don't you think Project:Python/PYTHON_TARGETS is sufficient explanation?
--Charles17 (talk) 09:53, 13 December 2020 (UTC)
Thanks for your answer. Project:Python/PYTHON_TARGETS only offers the text: 'These essentially control what version of Python the package will reference during and after installation'. Unfortunately it does not say what the difference is and how these variables work. My assumption is that PYTHON_SINGLE_TARGET is used for applications, and specifies which Python version will be used for running that application, and that PYTHON_TARGETS is used for modules and instructs Portage to build modules for the listed python versions. Is this correct? Also, what is the relation then between PYTHON_SINGLE_TARGET and eselect python? Eselect python also lists which interpretor should be used, right? Hfern (talk) 10:45, 13 December 2020 (UTC)
I have tried to clarify what to do when a profile update causes a Python upgrade, added a section for that in the main page Hfern (talk) 09:29, 3 January 2021 (UTC)