diff options
author | Richard Darst <rkd@zgib.net> | 2009-06-13 03:19:30 (GMT) |
---|---|---|
committer | Richard Darst <rkd@zgib.net> | 2009-06-13 03:19:30 (GMT) |
commit | d35a01af694068e4ac0fa1538089df2c708a3c88 (patch) | |
tree | 4673682d446055a35aac24c4aa00919b3ecf0bf8 /meeting.py | |
parent | cf74dd1c8d8bfa0e2b3f3fdb87587df1cdc1b5f9 (diff) |
Fix problem when parsing logfiles: some nicks not seen
- Previous parsing regexp's assumed only a-zA-Z0-9_ , which clearly isn't
enough for many IRC nicks. To fix this, switch to an inverse regexp
match: [^ ]+ or [^>]+ count as nicks, that is, anything except a
space or >. I hope that will do it.
- To Do: make sure that logs from other clients can be parsed, too.
darcs-hash:20090613031930-82ea9-a11860f49d2feaeeb3aeebc68864a46a200802c1.gz
Diffstat (limited to 'meeting.py')
-rw-r--r-- | meeting.py | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -85,8 +85,8 @@ def parse_time(time_): except ValueError: pass try: return time.strptime(time_, "%H:%M") except ValueError: pass -logline_re = re.compile(r'\[?([0-9: ]*)\]? ?<([ \w]+)> (.*)') -loglineAction_re = re.compile(r'\[?([0-9: ]*)\]? \* ([\w]+) (.*)') +logline_re = re.compile(r'\[?([0-9: ]*)\]? *<[@+]?([^>]+)> *(.*)') +loglineAction_re = re.compile(r'\[?([0-9: ]*)\]? *\* *([^ ]+) *(.*)') # load custom local configurations try: |