Crash occurs at the very end of canonical-certification-server run complaining of "Unsupported Option: with sys-info"
Bug #1302685 reported by
Kent Baxley
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Next Generation Checkbox (CLI) |
Fix Released
|
High
|
Daniel Manrique |
Bug Description
The canonical-
http://
checkbox-ng 0.3-dev+
plainbox-
Related branches
lp:~roadmr/checkbox/1302685-quirky-exporter-options
- Zygmunt Krynicki (community): Approve
-
Diff: 23 lines (+8/-4)1 file modifiedcheckbox-ng/checkbox_ng/commands/cli.py (+8/-4)
Changed in checkbox-ng: | |
assignee: | nobody → Daniel Manrique (roadmr) |
milestone: | none → 0.3 |
Changed in checkbox-ng: | |
status: | In Progress → Fix Committed |
Changed in checkbox-ng: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
THanks! The culprit is checkbox_ ng/commands/ cli.py. It creates a list of exporters to save the report in various formats (code trimmed for brevity, look at the actual file for context):
Then it initializes them all with the same set of options:
exporter = exporter_cls(
['with- sys-info' , 'with-summary', 'with-job- description' ,
'with- text-attachment s'])
for exporter_cls in exporter_list:
# Options are only relevant to the XLSX exporter
This is relying on the old behavior of XML and HTML exporters not supporting (and thus ignoring) options to the constructor.
Recently the XML exporter started supporting a single option, so it no longer ignores the parameter to the constructor. Since at least one of the options passed here (['with-sys-info']) is unsupported by the xml exporter, this causes the crash you see.
Exporters already know how to reject unknown options (which is what happens here), so the fix is to change this instance (and possibly others; I'll hunt down any offenders) so they don't send unsupported options to exporters.