Why is Blender's Python interpreter always in debug mode?

In Python there is a way to optimize certain things on script execution by passing the -O flag which removes docstrings from runtime, and most importantly, sets the built-in constant __debug__ to False, which makes the interpreter completely ignore the execution of assertions and any debug-specific code.

Is there any specific reason Blender’s Python interpreter always runs in debug mode without optimization enabled? That is definitely useful for addon debugging and development, but simply ignoring assertions could provide a significant performance increase for some python packages if they are used in the addon.

Maybe because some “developers” are just copy and pasting something ( nowadays even using chat-ai to make anything ) and if it crashes then blender would be blamed ??
You might consider this thought… so the blender developer just said: damn no… :wink:

So do you want it fast (and doing backups before every step… so not so fast then…) or a bit more secure (stopping crashes by respect some assertions) ?

( And of course you could try to compile it that way… and report about the speed gain…)