code: def create_shell(shell=None, **kwargs):
      
      if not shell:
          shell = config.default_shell
          if not shell:
              from rez.system import system
              shell = system.shell
  
      from rez.plugin_managers import plugin_manager
      return plugin_manager.create_instance('shell', shell, **kwargs)
docs: Returns a Shell of the given type, or the current shell type if shell
      is None.