code: def _get_handler(self, namespace, remove_handler=False):
          
          if hasattr(namespace, '_func'):
              _func = namespace._func
              if remove_handler:
                  del namespace._func
              return _func
docs: Get a handler (if present) from a namespace.
  
          Returns
          -------
          function or None
              The handler defined in the namespace.