This effectively disables automatic .pyc file generation and loading of __pycache__ files, which is stronger and more reliable than setting PYTHONDONTWRITEBYTECODE.
Historically, we have supported sys.implementation.cache_tag is None (it's throughout about half the relevant tests), but there's some work to do to get other tests to properly check.
The only build-time option I'm proposing is a preprocessor define that isn't set by default, and when set will set cache_tag to None rather than the default value. Patching in a preprocessor define is much easier to maintain than replacing the code, and I expect anyone who needs this (such as myself) is likely already patching other parts of the source and can easily add a define.
Linked PRs
This effectively disables automatic .pyc file generation and loading of
__pycache__files, which is stronger and more reliable than settingPYTHONDONTWRITEBYTECODE.Historically, we have supported
sys.implementation.cache_tag is None(it's throughout about half the relevant tests), but there's some work to do to get other tests to properly check.The only build-time option I'm proposing is a preprocessor define that isn't set by default, and when set will set
cache_tagto None rather than the default value. Patching in a preprocessor define is much easier to maintain than replacing the code, and I expect anyone who needs this (such as myself) is likely already patching other parts of the source and can easily add a define.Linked PRs