code: def require_resource(self, type: Type[T_Resource], name: str = 'default') -> T_Resource:
          
          resource = self.get_resource(type, name)
          if resource is None:
              raise ResourceNotFound(type, name)
  
          return resource
docs: Look up a resource in the chain of contexts and raise an exception if it is not found.
  
          This is like :meth:`get_resource` except that instead of returning ``None`` when a resource
          is not found, it will raise :exc:`~asphalt.core.context.ResourceNotFound`.
  
          :param type: type of the requested resource
          :param name: name of the requested resource
          :return: the requested resource
          :raises asphalt.core.context.ResourceNotFound: if a resource of the given type and name was
              not found