title: Is it possible to change the Environment of a parent process in Python?
body: <p>In Linux When I invoke python from the shell it replicates its environment, and starts the python process. Therefore if I do something like the following:</p>
  
  <pre><code>import os
  os.environ["FOO"] = "A_Value"
  </code></pre>
  
  <p>When the python process returns, FOO, assuming it was undefined originally, will still be undefined. Is there a way for the python process (or any child process) to modify the environment of its parent process?</p>
  
  <p>I know you typically solve this problem using something like</p>
  
  <pre><code>source script_name.sh
  </code></pre>
  
  <p>But this conflicts with other requirements I have.</p>