code: def disconnect(self):
          
          # here we just request the disconnection
          # later in _handle_eio_disconnect we invoke the disconnect handler
          for n in self.namespaces:
              self._send_packet(packet.Packet(packet.DISCONNECT, namespace=n))
          self._send_packet(packet.Packet(
              packet.DISCONNECT, namespace='/'))
          self.eio.disconnect(abort=True)
docs: Disconnect from the server.