git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [Question] Moving from Python2 to Python3

From
NSNikolay Shustov <nikolay.shustov@gmail.com>
Date
Mar 26, 2025, 01:56 UTC
Message-ID
<77b5fa59-a8a1-4859-8f3d-41f94fa8120d@gmail.com>
In-Reply-To
<Z-NSGtV06NPE_C9D@teonanacatl.net>

Doh! Of course I thought of PYTHONPATH not of PYTHON_PATH. My apologies for the noise.

On 3/25/25 21:02, Todd Zullinger wrote:
Show 30 quoted lines
> Nikolay Shustov wrote:
>> You are right, my answer was over-engineered.
>>
>> Instead of speculating about what else needs to be done if
>> one decides to set PYTHONPATH, I should have just advised
>> to use the OS specific method on setting up the "default"
>> Python as Python3 and be with it.
>>
>> Well, unless the dual Python is needed (git-p4 running
>> with the Python different from system "default").
> Perhaps you were conflating PYTHON_PATH, which brian
> suggested, with PYTHONPATH?
>
> PYTHON_PATH is used by the git build system to set the path
> to the python executable, e.g.: /usr/bin/python2,
> /usr/bin/python3, etc.
>
> PYTHONPATH is used by python itself to point to the
> location(s) of module files, similar to PATH, as you
> mentioned.
>
> The Fedora distribution packaging set PYTHON_PATH to python2
> or python3 while both were available and things worked well.
> Only python3 is supported now, and PYTHON_PATH is set
> accordingly.
>
> That ought to work just as well for NonStop.  If it doesn't,
> that would most likely be something to take up with the OS
> folks handling python3. :)
>
Previous: Todd Zullinger
Message 7 of 7 in “[Question] Moving from Python2 to Python3”
  1. rsbecker@nexbridge.comMar 25, 2025
  2. brian m. carlsonMar 25, 2025
  3. Nikolay ShustovMar 25, 2025
  4. Junio C HamanoMar 25, 2025
  5. Nikolay ShustovMar 25, 2025
  6. Todd ZullingerMar 26, 2025
  7. Nikolay ShustovMar 26, 2025

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.