21 Commits

Author SHA1 Message Date
skizzerz
6d401fd461 Don't try to add new users if we're changing usermodes on ourselves.
The actor in this case will either be ourself (in which case users.Bot
already exists), or a services nick (which may not have a full hostmask,
and therefore cause hashing errors). Only try to add a user if we're
changing a channel mode. This may still break on chanmodes, needs more
testing in that regard.
2018-01-05 13:04:42 -07:00
Vgr E. Barry
ebd7f24f41 Updating the event_hosthidden handler 2017-12-30 09:51:59 -05:00
Vgr E. Barry
b3687268c2 Handle the bot itself changing nicks 2017-12-29 10:10:11 -05:00
Ryan Schmidt
0b07d9193f Convert var.DISCONNECTED to users (#302)
* Fix inaccuracy in users._add docstring

Also don't track disconnected users by nick anymore. But that seems less
major than fixing the docstring.

* Fixes

* Fix docstring
2017-12-04 14:06:20 -05:00
skizzerz
68109a12ae Fix RPL_ISUPPORT parsing
Instead of trying to guess what format a token is based on its content,
hardcode a list of known tokens and what formats their parameters take.
Any unknown token will therefore be kept as a string, instead of
potentially blowing up parsing due to unexpected values (such as
multiple colons).

Also fix parsing for colon-separated lists. MAXLIST=beI:100 is *VERY*
different from MAXLIST=b:100,e:100,I:100 but our previous processing
made the two identical in terms of what the structure looked like.
2017-05-15 16:24:20 -05:00
Vgr E. Barry
64eb34a61a Properly handle the bot's host change 2017-04-07 16:52:35 -04:00
skizzerz
29d8423b25 Fire part/quit event before removing user from channels
Before, strong refs ensured that the user stayed "alive" but now we
remove user instances when they leave the last channel. As such, fire
the event before removing them from channels so the user instance is
still in our overall user set.
2017-02-09 14:22:48 -06:00
Vgr E. Barry
a620860cc5 Update who_end event parameter 2017-01-13 11:57:16 -05:00
Vgr E. Barry
81c96f4a56 Tweak hooks.quit 2017-01-12 12:43:41 -05:00
Vgr E. Barry
d78f0e5179 Fix realname being a space breaking handling 2017-01-01 11:01:33 -05:00
Vgr E. Barry
85f8f9717a Change variable name to be more informative 2016-12-19 13:09:47 -05:00
Vgr E. Barry
c26c7887bc Add a hook for account changes 2016-11-24 17:05:08 -05:00
Vgr E. Barry
c6864dd7e7 Fix wrong hook name
For some reason, the end of a quiet listing has a different hook name.
2016-11-17 10:03:04 -05:00
Vgr E. Barry
074548813f Delay some channel handling operations
Specifically, the mode handling and the end of list modes are delayed until the end of the WHO reply from the server. When the end of the WHO reply is received, all queued operations on the channel, if any, are triggered at once in the form of relevant events.
2016-11-17 10:01:25 -05:00
Vgr E. Barry
3e61e9ec6a Beauty is in the eye of the tiger 2016-11-15 20:37:40 -05:00
Vgr E. Barry
360204bf43 Massively improve user handling
This changes how users are handled, making it less likely to encounter duplicate users; in normal circumstances, duplicates shouldn't happen.
2016-11-15 19:54:42 -05:00
Vgr E. Barry
2244ed4370 Fix wrong function calls in user functions 2016-11-03 12:04:26 -04:00
Vgr E. Barry
d090e573b7 Greatly improve channel handling
This also does some more bits of rudimentary user handling, but most of it still remains to be done.

Note: This adds DEV_PREFIX to botconfig and LOG_PREFIX to settings (var), make sure to properly update your bot!
2016-11-02 22:31:54 -04:00
Vgr E. Barry
3de4469809 Comment out yet-to-be-tested hooks 2016-10-31 22:23:42 -04:00
Vgr E. Barry
795caa83fe Forward fixes for the new interface 2016-10-31 17:57:48 -04:00
Vgr E. Barry
f3e1273dbc Add a new hooks.py file 2016-10-27 19:15:33 -04:00