parameters: (name, import_)
return_statement: return module
docstring: Find and load the module.
docstring_summary: Find and load the module.
docstring_tokens: Find and load the module .
function: def _find_and_load(name, import_):
      """Find and load the module."""
      with _ModuleLockManager(name):
          module = sys.modules.get(name, _NEEDS_LOADING)
          if module is _NEEDS_LOADING:
              return _find_and_load_unlocked(name, import_)
  
      if module is None:
          message = ('import of {} halted; '
                     'None in sys.modules'.format(name))
          raise ModuleNotFoundError(message, name=name)
  
      _lock_unlock_module(name)
      return module
function_tokens: def _find_and_load ( name , import_ ) : with _ModuleLockManager ( name ) : module = sys . modules . get ( name , _NEEDS_LOADING ) if module is _NEEDS_LOADING : return _find_and_load_unlocked ( name , import_ ) if module is None : message = ( 'import of {} halted; ' 'None in sys.modules' . format ( name ) ) raise ModuleNotFoundError ( message , name = name ) _lock_unlock_module ( name ) return module