On 2/6/21, Christopher Barker <[email protected]> wrote:
> On Fri, Feb 5, 2021 at 12:59 PM Eryk Sun <[email protected]> wrote:
>
> But why limit it to that? If there are more things to configure in an
> environment-specific way — why not put it in this existing location?

I'd rather not limit the capability to just virtual environments.

> I'd prefer a new configuration file that sets the default values for
>> -X implementation-specific options. The mechanism for finding this
>> file can support virtual environments.
>
> Then wouldn’t that simply be two configuration  files that will be treated
> the same way?

Relative to the installation, "python.cfg" should only be found in the
same directory as the base executable, not its parent directory. If
"pyvenv.cfg" is found, then it's a virtual environment, and
"python.cfg" will also be looked for in the directory of "pyvenv.cfg",
and supersedes settings in the base installation.

> I’m still convinced that It is a bad idea to have User-wide Python
> configuration like this. The fact is that different Python apps (may) need
> different configurations, and environments are the way to support that.

Add an option in the installed "python.cfg" to set the name of the
organization and application. If not set, the organization and
application respectively default to "Python" and
"Python<major><minor>[-32]". Looking for system and user configuration
would be parameterized using that name, i.e.
"%ProgramData%\<organization>\<application>\python.cfg" and
"%LocalAppData%\<organization>\<application>\python.cfg".
_______________________________________________
Python-ideas mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/TXKCDQL3JNCUG52M265LU5O7USBWO7D6/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to