Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

install notes: update python install notes to not reference out of su…#1151

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
clintonsteiner wants to merge1 commit intorealpython:master
base:master
Choose a base branch
Loading
fromclintonsteiner:updatePythonVersionsInInstallNotes

Conversation

@clintonsteiner
Copy link

…pport python versions

  • Was updating some pypi packaging notes and saw a reference here
  • While looking - saw these were very out of date
  • Attempt to steer new developers towards newer versions of python that are still in support

…pport python versions* Was updating some pypi packaging notes and saw a reference here* While looking - saw these were very out of date* Attempt to steer new developers towards newer versions of python that  are still in support
At this point, you have the system Python available, and the Homebrew
version of Python 3 as well.

..code-block::console

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

9

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

correct

depending on you distribution. For example installing the ``python3.9`` package
on Fedora 32 to get Python 3.9. If you are a Fedora user, you might want
depending on you distribution. For example installing the ``python3.13`` package
on Fedora 32 to get Python 3.13. If you are a Fedora user, you might want

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Fedora releases new versions every 6 months, and unlike Ubuntu none of them have a support window longer than 13 months. My point here is, Fedora 32 is already unsupported and has been for 5 years. You could also never install Python 3.13 on it, because Python 3.13 didn't exist yet when F32 was in use.

The current Fedora release is 43, and the only other supported releases are 42 and 41. (But F41 support ends in two weeks.) Because of this rapid release cycle, it's best not to mentionany specific Fedora versions. They become outdated far too fast.

(Though, the other release mentioned by name is Ubuntu 16.10, which has also been out of support for many years. Even Ubuntu's 16.04, 18.04, and 20.04 LTS releases are past the end of their standard support lifetimes, and have moved into extended support. So, mentioning specific Ubuntu releases is perhaps also best avoided.)

Comment on lines 87 to 88
Note that on some Linux distributions including Ubuntu and Fedora the ``pip``
command is meant for Python 2, while the ``pip3`` command is meant for Python 3.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

This is no longer true for Fedora, and I doubt it is for Ubuntu either. Since Python 2 passed end-of-life,pip ==pip3 pretty much everywhere, withpip2 possibly being available forpython2.7.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

(Note that runningpip3, like runningpython3, is always an option to ENSURE you're using the Python 3 version of the tool. It's just no longernecessary as Python 3 is the default everywhere now.)

Comment on lines +23 to +28
If you're using another version of Ubuntu (e.g. the latest LTS release) or you want to use a more current Python, we recommend using the `deadsnakes PPA<https://launchpad.net/~deadsnakes/+archive/ubuntu/ppa>`_ to install Python 3::

$ sudo apt-get install software-properties-common
$ sudo add-apt-repository ppa:deadsnakes/ppa
$ sudo apt-get update
$ sudo apt-get install python3.8
$ sudo apt-get install python3
Copy link

@ferdnycferdnycNov 13, 2025
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

This won't work — the deadsnakes repo doesn'thave apython3 package. It provides Python versionsother than the one the distro provides aspython3, using package names likepython3.9 orpython3.11. (For 22.04 it provides all butpython3.10 which is the distropython3, and for 24.04 it omitspython3.12 because that's that release'spython3. But to install any deadsnakes Python package, you have to pick a specific version.)

Copy link

@ferdnycferdnyc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Some notes on the macOS side of things

If your Mac OS X version is between the above versions,
you do not need to install or configure anything else to use Python 2. These
instructions document the installation of Python 3.
you do not need to install or configure anything else to use Python.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I don't think this is a good change, on its own. As the doc says, macOS between those versionsdoes come with Python 2.7, specifically. There's no Python 3 on macOS 10.8-12.3 unless you install it. On those macOS systems,/usr/bin/python ==/usr/bin/python2 ==/usr/bin/python2.7.

Most users today will have alater version of macOS, which will come with Python 3, but the changes here don't sufficiently document that fact.

To cover more current releases, the docs should either drop any mentions of macOS 10.8-12.3 to go with the removal of the Python 2 language, or there should be additional text added that's specific to macOS 13 and higher, which discusses the default systempython3.

Comment on lines 29 to 38
Before installing Python, you'll need to install GCC. GCC can be obtained
by downloading `Xcode<https://developer.apple.com/xcode/>`_, the smaller
`Command Line Tools<https://developer.apple.com/downloads/>`_ (must have an
Apple account) or the even smaller `OSX-GCC-Installer<https://github.com/kennethreitz/osx-gcc-installer#readme>`_
package.

..note::
If you already have Xcode installed, do not install OSX-GCC-Installer.
In combination, the software can cause issues that are difficult to
diagnose.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

The OSX GCC Installer project stopped being supported when Apple released the Command Line Tools as a separate package. It was last available for OS X 10.7, and today there are no longer any installers provided by the project. All mentions of it should be deleted from the docs.

Suggested change
Before installing Python, you'll need to install GCC. GCC can be obtained
by downloading `Xcode<https://developer.apple.com/xcode/>`_ or the smaller
`Command Line Tools<https://developer.apple.com/downloads/>`_ (must have an
Apple account).

Copy link

@ferdnycferdnycNov 13, 2025
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

(GitHub messes up suggested changes for ranges outside the PR, so this can't be applied as it's shown here. The suggestion is actually a change for lines 29-38.)


..code-block::console
$ /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

The default branch name has been changed, and the current recommended command line is,

/bin/bash -c"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Comment on lines 57 to 69
Once you've installed Homebrew, insert the Homebrew directory at the top
of your:envvar:`PATH` environment variable. You can do this by adding the following
line at the bottom of your:file:`~/.profile` file

..code-block::console
export PATH="/usr/local/opt/python/libexec/bin:$PATH"
If you have OS X 10.12 (Sierra) or older use this line instead

..code-block::console
export PATH=/usr/local/bin:/usr/local/sbin:$PATH

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

The Homebrew install script provides instructions on how to modify the user's profile to insert the right paths, and the instructions here will bewrong for most installs.

(On macOS 10.15 when usingzsh as the shell, it displays this:)

$/bin/bash -c"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"[...]==> Next steps:- Run these commands in your terminal to add Homebrew to your PATH:    echo >> /Users/ferd/.zprofile    echo 'eval "$(/usr/local/bin/brew shellenv)"' >> /Users/ferd/.zprofile    eval "$(/usr/local/bin/brew shellenv)"- Run brew help to get started- Further documentation:    https://docs.brew.sh

It's probably better to just say something like, "When Homebrew finishes installing, be sure to follow the instructions it displays to correctly update your$PATH."


..code-block::console
$ brew install python

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Especially on newer macOS releases which already provide a Python 3, it might be better to structure these docs more like the Linux docs, and discuss the possibility of installingadditional Python versions by specific number. Homebrew allowsbrew install python@3.9,brew install python@3.14, etc. to install additional interpreter versions, just like on Fedora or Ubuntu-with-deadsnakes.

brew install python will install whatever Python version is Homebrew'sdefault (currentlypython@3.14), so it's still a useful command, but it's no longer "install[ing] Python 3" if Python 3 is already preinstalled by Apple. It's installingHomebrew's default Python 3.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

2 more reviewers

@ferdnycferdnycferdnyc left review comments

@mandervrikmandervrikmandervrik approved these changes

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@clintonsteiner@ferdnyc@mandervrik

[8]ページ先頭

©2009-2025 Movatter.jp