cinchrb / cinch

The IRC Bot Building Framework
http://www.rubydoc.info/gems/cinch
MIT License
1k stars 180 forks source link

parse_modes error, uninitialized constants #163

Closed eddiegalvez closed 10 years ago

eddiegalvez commented 10 years ago
[2014/05/09 10:15:58.053] >> :frank!frank@irc.xxxx.com MODE #general -v frank : away
[2014/05/09 10:15:58.054] !! /Library/Ruby/Gems/2.0.0/gems/cinch-2.1.0/lib/cinch/mode_parser.rb:51:in `parse_modes': uninitialized constant Cinch::ModeParser::InvalidModeString (NameError)
[2014/05/09 10:15:58.054] !!    /Library/Ruby/Gems/2.0.0/gems/cinch-2.1.0/lib/cinch/irc.rb:451:in `on_mode'
[2014/05/09 10:15:58.054] !!    /Library/Ruby/Gems/2.0.0/gems/cinch-2.1.0/lib/cinch/irc.rb:263:in `parse'
[2014/05/09 10:15:58.054] !!    /Library/Ruby/Gems/2.0.0/gems/cinch-2.1.0/lib/cinch/irc.rb:151:in `block (2 levels) in start_reading_thread'
[2014/05/09 10:15:58.054] !!    /Library/Ruby/Gems/2.0.0/gems/cinch-2.1.0/lib/cinch/helpers.rb:122:in `rescue_exception'
[2014/05/09 10:15:58.055] !!    /Library/Ruby/Gems/2.0.0/gems/cinch-2.1.0/lib/cinch/irc.rb:149:in `block in start_reading_thread'
dominikh commented 10 years ago

42e189f (on the maint branch) fixes the issue of not properly raising InvalidModeString. Even with that change, however, you will get an exception, because I can't see how -v frank : away is a valid mode string.

That'd be a different issue, however. Feel free to file one, if you can shed any light on that format.

eddiegalvez commented 10 years ago

The use case came from connecting to Slack via their IRC Gateway thing. Assuming cinch was reporting on its console exactly what it was receiving, that's what it saw...

On Fri, May 9, 2014 at 4:24 PM, Dominik Honnef notifications@github.comwrote:

42e189f https://github.com/cinchrb/cinch/commit/42e189f (on the maint branch) fixes the issue of not properly raising InvalidModeString. Even with that change, however, you will get an exception, because I can't see how -v frank : away is a valid mode string.

That'd be a different issue, however. Feel free to file one, if you can shed any light on that format.

— Reply to this email directly or view it on GitHubhttps://github.com/cinchrb/cinch/issues/163#issuecomment-42709524 .