-X frozen_modules=on|off should be configurable with environment variable #98697
Labels
interpreter-core
(Objects, Python, Grammar, and Parser dirs)
type-feature
A feature request or enhancement
Feature or enhancement
-X frozen_modules=on|off
should be configurable with environment variablePitch
The crossenv project provides the ability to generate virtualenvs that are customized to allow very simple cross-compilation, by mixing pieces of a host-native python and the right configuration variables from a cross-compiled python. Python 3.11 broke it in a few ways, but in particular the way that it injects its hooks is by overriding the contents of
site.py
, which is now included in a frozen module by default. To allow the patching to continue working, we have to add the -X option to the python command line each time it starts. This is doable, but it would be much simpler if we could just set an environment variable to disable the frozen modules.Many other -X options are configurable through an environment variable, it seems like this one should too. Maybe
PYUSEFROZENMODULES=0|1
?Note: yes, crossenv does a lot of dirty tricks to do its work, but I've tried several cross-compilation approaches and it's the easiest I've used by far.
Previous discussion
No prior discussion, seems like a small enough feature that is an easy yes/no?
The text was updated successfully, but these errors were encountered: