Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-5192

undefined method `[]' for Puppet::Transaction::Event with certain reports

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: PUP 4.2.1
    • Fix Version/s: PUP 4.3.0
    • Component/s: None
    • Labels:
      None
    • Environment:

      Puppet AIO

    • Template:
    • Story Points:
      0
    • Sprint:
      Client 2015-09-30
    • Release Notes:
      Bug Fix
    • Release Notes Summary:
      Hide
      PUP-3272 introduced a regression where you could not load a report containing status events, e.g. YAML.load_file("last_run_report.yaml"). This ticket fixes fixes that and adds tests to ensure we don't regress.
      Show
      PUP-3272 introduced a regression where you could not load a report containing status events, e.g. YAML.load_file("last_run_report.yaml"). This ticket fixes fixes that and adds tests to ensure we don't regress.

      Description

      When Calling the function "YAML.load_file(path)" with a yaml file where a resource_statuses: member has events: non-empty, we get a "undefined method `[]' for #<Puppet::Transaction::Event:0x0000000341e3f0>" error.

      See attached files and gist.

        Attachments

        1. RESULT
          4 kB
        2. test.rb
          0.7 kB
        3. test.yaml
          4 kB

          Issue Links

            Activity

              People

              Assignee:
              qa qa
              Reporter:
              roidelapluie Julien Pivotto
              QA Contact:
              Eric Thompson
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Zendesk Support