The Puppet Labs Issue Tracker has Moved: https://tickets.puppetlabs.com

Bug #2342

Facter::Manufacturer.dmi_find_system_info truncates final character of last value of each Handle

Added by Frank Sorenson about 5 years ago. Updated over 3 years ago.

Status:ClosedStart date:06/14/2009
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:library
Target version:1.5.9
Keywords: Affected Facter version:
Branch:

We've Moved!

Ticket tracking is now hosted in JIRA: https://tickets.puppetlabs.com

This issue is currently not available for export. If you are experiencing the issue described below, please file a new ticket in JIRA. Once a new ticket has been created, please add a link to it that points back to this Redmine ticket.


Description

dmi_find_system_info cuts of the last character of the last value in a handle. For example, with dmidecode output:

Handle 0x0300, DMI type 3, 13 bytes
Chassis Information
        Manufacturer: Dell Inc.
...
        Security Status: None

a query for ‘Chassis Information’ => ‘Security Status’ will return ‘Non’, rather than the expected ‘None’.

and single character results, such as:

Physical Memory Array
        Location: System Board Or Motherboard
...
        Number Of Devices: 2

do not return a value, so no fact is created.

The offending line appears to be:

  if line =~ /#{key}/ and ( line =~ /#{value} 0x\d+ \(([-\w].*)\)\n*./ or line =~ /#{value} ([-\w].*)\n*./ )

There is likely a simple fix, however I have not mastered ruby well enough to fix the bug myself.

History

#1 Updated by James Turnbull about 5 years ago

  • Category set to library
  • Status changed from Unreviewed to Accepted
  • Target version set to 1.6.0

#2 Updated by James Turnbull over 4 years ago

  • Target version changed from 1.6.0 to 1.5.8

#3 Updated by James Turnbull over 4 years ago

  • Target version changed from 1.5.8 to 1.6.0

#4 Updated by James Turnbull over 3 years ago

  • Status changed from Accepted to Closed
  • Target version changed from 1.6.0 to 1.5.9

This appears to have been fixed in a refactor.

Also available in: Atom PDF