Closed
Bug 985612
Opened 10 years ago
Closed 10 years ago
mozlog.structured.commandline.setup_logging doesn't handle ArgumentParser.parse_args return value
Categories
(Testing :: Mozbase, defect)
Testing
Mozbase
Tracking
(Not tracked)
RESOLVED
FIXED
mozilla31
People
(Reporter: ted, Assigned: ted)
Details
Attachments
(1 file)
2.82 KB,
patch
|
jgraham
:
review+
|
Details | Diff | Splinter Review |
mozlog.structured.commandline.setup_logging has an example in the docs showing that you can pass the return value of ArgumentParser.parse_args to it, but that doesn't actually work because it's not a dict it's some sort of object. There's an easy workaround, which is to pass vars(args), but that's kind of clumsy. I think we should just handle these objects since it's fairly trivial and makes the API easier to use.
Assignee | ||
Comment 1•10 years ago
|
||
This just moves the workaround into setup_logging, and adds a really simple unittest to prove that it works.
Attachment #8393714 -
Flags: review?(james)
Assignee | ||
Updated•10 years ago
|
Assignee: nobody → ted
Status: NEW → ASSIGNED
Updated•10 years ago
|
Attachment #8393714 -
Flags: review?(james) → review+
Assignee | ||
Comment 2•10 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/e2d226ed6926
Comment 3•10 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/e2d226ed6926
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla31
You need to log in
before you can comment on or make changes to this bug.
Description
•