code: def start_client(self, language):
          
          started = False
          if language in self.clients:
              language_client = self.clients[language]
              queue = self.register_queue[language]
  
              # Don't start LSP services when testing unless we demand
              # them.
              if running_under_pytest():
                  if not os.environ.get('SPY_TEST_USE_INTROSPECTION'):
                      return started
  
              # Start client
              started = language_client['status'] == self.RUNNING
              if language_client['status'] == self.STOPPED:
                  config = language_client['config']
  
                  if not config['external']:
                      port = select_port(default_port=config['port'])
                      config['port'] = port
  
                  language_client['instance'] = LSPClient(
                      parent=self,
                      server_settings=config,
                      folder=self.get_root_path(language),
                      language=language
                  )
  
                  # Connect signals emitted by the client to the methods that
                  # can handle them
                  if self.main and self.main.editor:
                      language_client['instance'].sig_initialize.connect(
                          self.main.editor.register_lsp_server_settings)
  
                  logger.info("Starting LSP client for {}...".format(language))
                  language_client['instance'].start()
                  language_client['status'] = self.RUNNING
                  for entry in queue:
                      language_client.register_file(*entry)
                  self.register_queue[language] = []
          return started
docs: Start an LSP client for a given language.