code: def environment(env):
      def set_env(e):
          os.environ.clear()
          for k, v in e.items():
              os.environ[k] = v
  
      stored = os.environ.copy()
      try:
          set_env(env or {})
          yield
      finally:
          set_env(stored)
  
file_path: catboost/library/python/tmp/__init__.py
imports: import logging
  import tempfile
  import time
  import os
  import shutil
  import contextlib
  import library.python.fs
  import library.python.unique_id
label_desc: Use image node_id 8 for calling a global function with example usage: environment(env) without return types