You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Support configuring -X frozen_modules=on|off using an environment variable. #111374
This makes it harder for environments that you don't have the control over the flags passed to the Python interpreter.
#98697 also includes a use case for crossenv, but the issue was closed because it was not in time for Python 3.11.
I'm proposing a PYTHONFROZENMODULESPYTHON_FROZEN_MODULES environment variable to be added for Python 3.13, which has the equivalent meaning of using -X frozen_modules.
Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
#98697 is the same request, but closed due to not in time for Python 3.11.
changed the title [-]Support configuring frozen_module=on|off using an environment variable.[/-][+]Support configuring -X frozen_modules=on|off using an environment variable.[/+]on Oct 27, 2023
Activity
[-]Support configuring frozen_module=on|off using an environment variable.[/-][+]Support configuring -X frozen_modules=on|off using an environment variable.[/+]yilei commentedon Oct 27, 2023
Btw, I'll also send a PR, assuming this will be accepted.
hugovk commentedon Oct 28, 2023
I'll let others review the PR, but if we do this, let's add underscores to the name:
PYTHON_FROZEN_MODULESSee https://discuss.python.org/t/change-environment-variable-style/35180?u=hugovk
gh-111374: Add a new PYTHON_FROZEN_MODULES env var, equivalent of `-X…
pythongh-111374: Add a new PYTHON_FROZEN_MODULES env var, equivalent …
hugovk commentedon Nov 9, 2023
Thank you for your contribution!
pythongh-111374: Add a new PYTHON_FROZEN_MODULES env var, equivalent …
pythongh-111374: Add a new PYTHON_FROZEN_MODULES env var, equivalent …