def get_env_for_subprocess_command():
 env = os.environ.copy()
 if ('PYTHONPATH' in env):
  del env['PYTHONPATH']
 return env

def get_env_for_subprocess_command ( ) : env = os . environ . copy ( ) if ( 'PYTHONPATH' in env ) : del env [ 'PYTHONPATH' ] return env
retrieve environment to be used with the subprocess command .