code: def make_nameko_helper(config):
      
      module = ModuleType('nameko')
      module.__doc__ = """Nameko shell helper for making rpc calls and dispatching
  events.
  
  Usage:
      >>> n.rpc.service.method()
      "reply"
  
      >>> n.dispatch_event('service', 'event_type', 'event_data')
  """
      proxy = ClusterRpcProxy(config)
      module.rpc = proxy.start()
      module.dispatch_event = event_dispatcher(config)
      module.config = config
      module.disconnect = proxy.stop
      return module
docs: Create a fake module that provides some convenient access to nameko
      standalone functionality for interactive shell usage.