[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Paul Moore
On Thu, 21 Jul 2022 at 16:45, Christopher Barker wrote: > I still am dumbfounded that this wasn’t platform I dependent in the first > place, but you know what essay about hindsight. > Indeed. I've no idea why we had the difference in the first place, but that's water under the bridge at this

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Christopher Barker
I still am dumbfounded that this wasn’t platform I dependent in the first place, but you know what essay about hindsight. However, I’m no Windows expert, but I *think* the modern Windows file system(s?) support something like symlinks. It’s an under-the-hood feature, but maybe it’s possible to

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Simão Afonso
On 2022-07-21 17:04:16, Svein Seldal wrote: > https://github.com/pypa/pip/blob/main/src/pip/_internal/locations/_distutils.py#L145-L148 This actually works great! If the "Scripts" folder does not exist, it uses "bin". >

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Svein Seldal
On 2022-07-21 13:05, Paul Moore wrote: On Thu, 21 Jul 2022 at 11:33, Thomas Grainger Is this the canonical location of this information? https://github.com/python/cpython/blob/3.10/Lib/sysconfig.py#L56 In theory, yes. In practice, if that worked, we wouldn't get people asking about

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Thomas Grainger
I'd recommend writing a virtualenv plugin that configures https://virtualenv.pypa.io/en/latest/extend.html#virtualenv.discovery.discover.Discover Overriding the interpreter install path here:

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Simão Afonso
On 2022-07-21 12:00:18, Paul Moore wrote: > How would that work? Would the value of bin-name be stored somewhere and > then all tools would need to refer to that rather than just selecting based > on platform like now? You'd still need to change all the tools, or your > choice of directory simply

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Paul Moore
On Thu, 21 Jul 2022 at 11:33, Thomas Grainger wrote: > > A practical approach may be to develop some form of library that "hides" > the difference behind some form of API for finding the correct value, get > that added to the stdlib and wait a few years until it's adopted everywhere > (because

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Paul Moore
On Thu, 21 Jul 2022 at 11:07, Simão Afonso wrote: > On 2022-07-21 09:55:21, Paul Moore wrote: > > A practical approach may be to develop some form of library that "hides" > > the difference behind some form of API for finding the correct value, get > > that added to the stdlib and wait a few

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Thomas Grainger
> A practical approach may be to develop some form of library that "hides" the difference behind some form of API for finding the correct value, get that added to the stdlib and wait a few years until it's adopted everywhere (because it's so well-designed and convenient ;-)) Then, you can change

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Simão Afonso
On 2022-07-21 09:55:21, Paul Moore wrote: > A practical approach may be to develop some form of library that "hides" > the difference behind some form of API for finding the correct value, get > that added to the stdlib and wait a few years until it's adopted everywhere > (because it's so

[Python-ideas] Re: Use 'bin' in virtual environments on Windows

2022-07-21 Thread Paul Moore
There is a *lot* of code that depends on the Windows directory being "Scripts". There have been proposals in the past to change it (sorry, no links but it has come up a few times on the various packaging forums), but it simply breaks too much for too little gain. If you're serious about wanting