New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
1.11 - import_logs.py broken parser #3805
Comments
please submit failing test or more info as it seems to work 2debefd#L0R14 |
Attachment: |
Can you try import attached gentoo.log directly? It fails for me with default import_logs.py. When I change -
back to what was there in 1.10.1 it works
so I guess the problem is somewhere there, but I cannot figure out what. thanks |
@matt, I found the issue w/ this bug and uploaded a fix in master...3805, can you review? Here's an explanation of the fix: Seems that the change of order to the format exposed a couple bugs. First the change I committed before isn't flexible enough w/ log files (like gentoo.log which is ncsa_extended w/ two extra fields). Also, regex quantifiers are greedy, so now that common gets tested before ncsa_extended, 'common' matches w/ incorrect groups and ncsa_extended is never tried. I've reverted my original change (the '\s*$' one) and modified the format autodetection logic to use the format that returns the most groups (ie, the one that matches and returns the most information). I've also modified the regexes to account for regex greediness. There are some extra tests and I fixed a bug w/ the S3 regex. |
all looks good to me! |
@matt Ok, greediness was only an issue w/ my change, so I've reverted that and added some more tests. I've pushed it again so you can take a look if you want. Will commit tomorrow. |
In 62b43d8: Fixes #3805, reverted change in log importer that looked for end-of-line after format regex match and modified format autodetection logic to pick the format based on whether the format matches and the number of groups returned in the match. Notes:
|
There's broken parser since 1.11
1.10.1
1.11
The text was updated successfully, but these errors were encountered: