code: def import_file(package: str, fname: str) -> ModuleType:
      
      mod_name = fname.rstrip('.py')
      spec = spec_from_file_location(mod_name, '{}/{}'.format(package, fname))
      module = module_from_spec(spec)
      spec.loader.exec_module(module)
      return module
docs: Import file directly.
  
      This is a hack to import files from packages without importing
      <package>/__init__.py, its purpose is to allow import without requiring
      all the dependencies at this point.
  
      Args:
          package: Package to import from
          fname: File to import
      Returns:
          Imported module