[issue46890] getpath problems with framework build

2022-04-05 Thread Ned Deily
Ned Deily added the comment: New changeset 6aaf4cd866f7c8f065d30d2a3fb4fffa8461d1d8 by Ronald Oussoren in branch 'main': bpo-46890: Fix setting of sys._base_executable with framework builds on macOS (GH-31958) https://github.com/python/cpython/commit/6aaf4cd866f7c8f065d30d2a3fb4fffa8461d1d8

[issue46890] getpath problems with framework build

2022-03-17 Thread Ronald Oussoren
Change by Ronald Oussoren : -- keywords: +patch pull_requests: +30047 stage: -> patch review pull_request: https://github.com/python/cpython/pull/31958 ___ Python tracker ___

[issue46890] getpath problems with framework build

2022-03-16 Thread Ronald Oussoren
Ronald Oussoren added the comment: venv requiring site isn't really a problem, although it is a bit weird that sys.prefix changes when using the -S flag. -- ___ Python tracker

[issue46890] getpath problems with framework build

2022-03-16 Thread Eryk Sun
Eryk Sun added the comment: > This means that "python -S" doesn't work with a virtual environment. Does that matter? I've only used a virtual environment to override or extend the system site packages. Is there a reason to use one without site packages? -- nosy: +eryksun

[issue46890] getpath problems with framework build

2022-03-16 Thread Steve Dower
Steve Dower added the comment: > I just noticed the same. Is this intentional? Honestly, no idea. I just copied how it was designed before, and had nothing to do with the original venv implementation. At a guess, I think virtualenv did everything with a patched site.py, so when it was

[issue46890] getpath problems with framework build

2022-03-16 Thread Ronald Oussoren
Ronald Oussoren added the comment: > However, it's the site.py module that actually updates sys.prefix for the > venv. So you may just be inspecting at the wrong point? Or possibly it's in a > codepath that doesn't run on macOS because *previously* it was being set > correctly in getpath

[issue46890] getpath problems with framework build

2022-03-14 Thread Steve Dower
Steve Dower added the comment: The sys module gets initialised in _PySys_UpdateConfig() in Python/sysmodule.c. It gets called later in pylifecycle.c. But it ought to just copy directly from the config. However, it's the site.py module that actually updates sys.prefix for the venv. So you

[issue46890] getpath problems with framework build

2022-03-13 Thread Ronald Oussoren
Ronald Oussoren added the comment: I've updated the title to better reflect the actual problem. An update on the current state of this issue: I haven't looked at the code for a couple of days because because I got stuck. With a fresh mind I've continued debugging and noticed that I'm