cpuinfo parser chokes on multiple : in output
Bug #1180496 reported by
Jeff Lane
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Checkbox |
Fix Released
|
Critical
|
Jeff Lane |
Bug Description
discovered that on some cpus, you could get a model string that looks like this:
model: AMD Processor: more info
the second ':' causes the parser to choke because it's splitting the string into 3 rather than 2 items.
Related branches
lp:~bladernr/checkbox/1180496-fix-cpuinfo-parser
- Daniel Manrique (community): Approve
-
Diff: 37 lines (+7/-3)2 files modifiedcheckbox/parsers/cpuinfo.py (+2/-3)
debian/changelog (+5/-0)
Changed in checkbox: | |
status: | In Progress → Fix Committed |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
simple fix, after we ganged up on it. The issue is that cpuinfo parser is splitting on all occurances of ':' rather than the first instance.
Changing this to limit maxsplit:
str.split( delimiter, maxsplit)
resolves the issue.