Weird SYSTEM dmi device names are mishandled

Bug #1850972 reported by Sheila Miguez
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Checkbox Support Library
Fix Released
High
Jonathan Cave

Bug Description

Discovered in lp:1850930

Some Lenovo systems have characters in their name that are not handled well.

For example,

Handle 0x0023, DMI type 1, 27 bytes
System Information
 Manufacturer: LENOVO
 Product Name: System x3550 M5: -[5463AC1]-
 Version: 07
 Serial Number: 06EEEAR
 UUID: 7b75005c-d029-11e4-9aa6-40f2e9b938a0
 Wake-up Type: Power Switch
 SKU Number: (none)
 Family: System X

From that, checkbox produces

  {
    "system_family": "System X",
    "system_product_name:_system_x3550_m5": "-[5463AC1]-",
    "system_serial": "06EEEAR",
    "system_sku_number": "(none)",
    "system_uuid": "7b75005c-d029-11e4-9aa6-40f2e9b938a0",
    "system_vendor": "LENOVO",
    "system_version": "07",
    "system_wake_up_type": "Power Switch",
    "category": "SYSTEM"
  },

Related branches

description: updated
Revision history for this message
Sheila Miguez (codersquid) wrote :

Maybe change the key regex to have [^:]+ instead of .+

Changed in checkbox-support:
importance: Undecided → High
milestone: none → 0.43.0
Revision history for this message
Jonathan Cave (jocave) wrote :

The job which exhibits the bug is id: raw_devices_dmi_json in plainbox-provider-checkbox. It runs the parser like this:

dmidecode | python3 -m plainbox dev parse dmidecode | jq '[.[] | ._attributes + {"category": .category}]'

Revision history for this message
Jonathan Cave (jocave) wrote :
Revision history for this message
Sylvain Pineau (sylvain-pineau) wrote :
Changed in checkbox-support:
status: New → Fix Committed
status: Fix Committed → New
Jonathan Cave (jocave)
Changed in checkbox-support:
status: New → Confirmed
assignee: nobody → Jonathan Cave (jocave)
status: Confirmed → In Progress
Changed in checkbox-support:
status: In Progress → Fix Committed
Changed in checkbox-support:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.