code: def get_local_environnement(self):
          
          # Do not use copy.copy() here, as the resulting copy still
          # changes the real environment (it is still a os._Environment
          # instance).
          local_env = os.environ.copy()
          for local_var in self.env:
              local_env[local_var] = self.env[local_var]
          return local_env
docs: Mix the environment and the environment variables into a new local
          environment dictionary
  
          Note: We cannot just update the global os.environ because this
          would effect all other checks.
  
          :return: local environment variables
          :rtype: dict