Python\'s access to environment variables does not accurately reflect the operating system\'s view of the processes environment.
os.getenv and os.environ do not func
Looking at the Python source code (2.4.5):
Modules/posixmodule.c gets the environ in convertenviron() which gets run at startup (see INITFUNC) and stores the environment in a platform-specific module (nt, os2, or posix)
Lib/os.py looks at sys.builtin_module_names, and imports all symbols from either posix, nt, or os2
So yes, it gets decided at startup. os.environ is not going to be helpful here.
If you really want to do this, then the most obvious approach that comes to mind is to create your own custom C-based python module, with a getenv that always invokes the system call.