Closed (fixed)
Project:
Bot
Version:
6.x-1.0
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
24 Sep 2008 at 21:47 UTC
Updated:
20 Feb 2009 at 01:50 UTC
Jump to comment: Most recent file
First off, thanks for the module!
I'm using this to run two bots now, one on #foo, and one on #foo-private. The problem is that going to http://example.com/bot/log/foo shows logs from BOTH channels.
The patch attached fixes this by adding a $ to the end of the REGEX in the SQL statement.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | correct_logs3.patch | 824 bytes | Steven Merrill |
| #1 | correct_logs2.patch | 819 bytes | Steven Merrill |
| correct_logs.patch | 863 bytes | Steven Merrill |
Comments
Comment #1
Steven Merrill commentedOops. New patch against the real, released 6.x-1.0 version. In any case, it's a one-character change.
Comment #2
morbus iffUnfortunately, this won't work. Consider a user who is in five channels and then QUITs. What is stored in the database's 'channel' column is "#channel1 #channel2 #channel3 #channel4 #channel5". Now, with your patch, if someone heads to the web-based logs for #channel3, they wouldn't get the QUIT message - it would appear as if the user never left the channel. This isn't that big of a deal, I heartily agree, but I think the stronger patch would be "(\s|$)" instead of "$" (untested). This way, we'd catch #channel3 in the above example, but also #channel5 (assuming that log was called, of course).
Thoughts?
Comment #3
Steven Merrill commentedMorbus,
That appears to work fine - I still get the proper messages on each channel when someone quits both, but no message pollution.
Here it is, re-rolled by hand.
And again, thanks - this is a great module!
Comment #4
Steven Merrill commentedApologies - I was having a bit of a blonde moment.
I'm now _not_ getting quit messages on both channels, but no more message pollution.
Comment #5
morbus iffMy bad - I wasn't immediately clear. Try
.*#%s(\s|$)for the *entirety* of the regexp (your current patch has a " ?" at the end of it which I suspect is causing the problem. If that doesn't work, I'll have to take a closer look at what's going on a bit later. Warhammer Online is calling ;)Comment #6
morbus iffCommitted.