@@ -188,7 +188,8 @@ def add_status(self, status, sort=True):
188188 """
189189 if status in self .status :
190190 logger .warning (
191- "[%s|chantrack] Attempted to add existing status to channel member: %s %s" ,
191+ "[%s|chantrack] Attempted to add existing status "
192+ "to channel member: %s %s" ,
192193 self .conn .name , self , status
193194 )
194195 else :
@@ -202,7 +203,8 @@ def remove_status(self, status):
202203 """
203204 if status not in self .status :
204205 logger .warning (
205- "[%s|chantrack] Attempted to remove status not set on member: %s %s" ,
206+ "[%s|chantrack] Attempted to remove status not set "
207+ "on member: %s %s" ,
206208 self .conn .name , self , status
207209 )
208210 else :
@@ -272,7 +274,9 @@ def join_channel(self, channel):
272274 """
273275 :type channel: Channel
274276 """
275- self .channels [channel .name ] = memb = channel .get_member (self , create = True )
277+ self .channels [channel .name ] = memb = channel .get_member (
278+ self , create = True
279+ )
276280 return memb
277281
278282 @property
@@ -477,7 +481,8 @@ def parse_names_item(item, statuses, has_multi_prefix, has_userhost):
477481 status , item = item [:1 ], item [1 :]
478482 user_status .append (statuses [status ])
479483 if not has_multi_prefix :
480- # Only remove one status prefix if we don't have multi prefix enabled
484+ # Only remove one status prefix
485+ # if we don't have multi prefix enabled
481486 break
482487
483488 user_status .sort (key = attrgetter ('level' ), reverse = True )
@@ -495,13 +500,18 @@ def replace_user_data(conn, chan_data):
495500 :type conn: cloudbot.client.Client
496501 :type chan_data: Channel
497502 """
498- statuses = {status .prefix : status for status in set (conn .memory ["server_info" ]["statuses" ].values ())}
503+ statuses = {
504+ status .prefix : status
505+ for status in set (conn .memory ["server_info" ]["statuses" ].values ())
506+ }
499507 new_data = chan_data .data .pop ("new_users" , [])
500508 new_users = KeyFoldDict ()
501509 has_uh_i_n = is_cap_available (conn , "userhost-in-names" )
502510 has_multi_pfx = is_cap_available (conn , "multi-prefix" )
503511 for name in new_data :
504- nick , ident , host , status = parse_names_item (name , statuses , has_multi_pfx , has_uh_i_n )
512+ nick , ident , host , status = parse_names_item (
513+ name , statuses , has_multi_pfx , has_uh_i_n
514+ )
505515 user_data = get_users (conn ).getuser (nick )
506516 user_data .mask = Prefix (nick , ident , host )
507517
@@ -510,7 +520,9 @@ def replace_user_data(conn, chan_data):
510520
511521 old_users = chan_data .users
512522 old_users .clear ()
513- old_users .update (new_users ) # Reassigning the dict would break other references to the data, so just update instead
523+ # Reassigning the dict would break other references to the data,
524+ # so just update instead
525+ old_users .update (new_users )
514526
515527
516528@hook .irc_raw (['353' , '366' ], singlethread = True )
0 commit comments