3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-27 21:19:31 +01:00

hybrid: Set irc.connected after receiving EOB

This commit is contained in:
Daniel Oaks 2016-03-30 15:48:44 +10:00
parent 4b14134a17
commit 153b77c4bb

View File

@ -225,7 +225,7 @@ class HybridProtocol(TS6BaseProtocol):
self.irc.uplink = numeric self.irc.uplink = numeric
def handle_capab(self, numeric, command, args): def handle_capab(self, numeric, command, args):
# We only get a list of keywords here. Charybdis obviously assumes that # We only get a list of keywords here. Hybrid obviously assumes that
# we know what modes it supports (indeed, this is a standard list). # we know what modes it supports (indeed, this is a standard list).
# <- CAPAB :BAN CHW CLUSTER ENCAP EOPMOD EUID EX IE KLN KNOCK MLOCK QS RSFNC SAVE SERVICES TB UNKLN # <- CAPAB :BAN CHW CLUSTER ENCAP EOPMOD EUID EX IE KLN KNOCK MLOCK QS RSFNC SAVE SERVICES TB UNKLN
self.irc.caps = caps = args[0].split() self.irc.caps = caps = args[0].split()
@ -233,9 +233,6 @@ class HybridProtocol(TS6BaseProtocol):
# if required_cap not in caps: # if required_cap not in caps:
# raise ProtocolError('%s not found in TS6 capabilities list; this is required! (got %r)' % (required_cap, caps)) # raise ProtocolError('%s not found in TS6 capabilities list; this is required! (got %r)' % (required_cap, caps))
log.debug('(%s) self.irc.connected set!', self.irc.name)
self.irc.connected.set()
def handle_server(self, numeric, command, args): def handle_server(self, numeric, command, args):
# <- SERVER charybdis.midnight.vpn 1 :charybdis test server # <- SERVER charybdis.midnight.vpn 1 :charybdis test server
sname = args[0].lower() sname = args[0].lower()
@ -404,7 +401,9 @@ class HybridProtocol(TS6BaseProtocol):
raise Exception('COULD NOT PARSE SVSTAG: {} {} {}'.format(numeric, command, args)) raise Exception('COULD NOT PARSE SVSTAG: {} {} {}'.format(numeric, command, args))
def handle_endburst(self, numeric, command, args): def handle_endburst(self, numeric, command, args):
pass log.debug('(%s) end of burst received', self.irc.name)
log.debug('(%s) self.irc.connected set!', self.irc.name)
self.irc.connected.set()
# empty handlers # empty handlers
# TODO: there's a better way to do this # TODO: there's a better way to do this