[Twisted-Python] Inheriting Environment (was: Wrapping blocking code)
warner at lothar.com
Mon Jul 28 14:50:22 EDT 2003
Itamar Shtull-Trauring <itamar at itamarst.org> writes:
> To expand on what Bob said, you may indeed want to pass os.environ as
> the env arg of spawnProcess.
We've talked about this briefly before, but perhaps this should be the
default? I think that "child inherits the environment of the parent" is the
most commonly expected behavior; that's why environment variables are not
the same as command-line arguments. Programs which change context somehow
(setuid) should clear their environment before spawning a process, but in
general the child is running with the same permissions as the parent, and I
think it is appropriate for them to operate in the same environment.
I've got a patch to implement this around here somewhere..
More information about the Twisted-Python