code: def _get_engineio_url(self, url, engineio_path, transport):
          
          engineio_path = engineio_path.strip('/')
          parsed_url = urllib.parse.urlparse(url)
  
          if transport == 'polling':
              scheme = 'http'
          elif transport == 'websocket':
              scheme = 'ws'
          else:  # pragma: no cover
              raise ValueError('invalid transport')
          if parsed_url.scheme in ['https', 'wss']:
              scheme += 's'
  
          return ('{scheme}://{netloc}/{path}/?{query}'
                  '{sep}transport={transport}&EIO=3').format(
                      scheme=scheme, netloc=parsed_url.netloc,
                      path=engineio_path, query=parsed_url.query,
                      sep='&' if parsed_url.query else '',
                      transport=transport)
docs: Generate the Engine.IO connection URL.