ayust / kitnirc

Python IRC bot framework.
MIT License
11 stars 7 forks source link

Add basic NICKNAMEINUSE handling #23

Closed flexd closed 9 years ago

flexd commented 9 years ago

This has been tested and works alright :-)

Sorry about the extra merge commit, can you squash it?

ayust commented 9 years ago

I'd prefer to avoid adding parsers from modules - there's no conflict resolution between them, so if two modules add a parser for the same event, one will be silently dropped.

There's two options here:

  1. Listen for RAWLINE events and see if they start with NICKNAMEINUSE - that wouldn't require any change to the core code.
  2. Add NICKNAMEINUSE as a core parser and then have the module listen for a real event.

Personally I'd rather do the second - it's a common enough case that it's worth having in core.

ayust commented 9 years ago

I've gone ahead and added a core client parser for NICKNAMEINUSE in 2865940d7f69b4c6795fe95319f8fe89113ca9d0.

flexd commented 9 years ago

Alright, I figured the parser would be best in the core as well. :-)