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

Resource defaults and resource overrides can lead to incorrect parameter conflicts

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: PUP 5.0.0
    • Fix Version/s: PUP 5.0.0
    • Component/s: None
    • Labels:
      None
    • Template:
    • Sub-team:
    • Team:
      Agent
    • Story Points:
      1
    • Sprint:
      Agent 2017-06-14
    • Method Found:
      Customer Feedback
    • Release Notes:
      Not Needed
    • Release Notes Summary:
      Problem in unreleased code.
    • QA Risk Assessment:
      Automate

      Description

      The error message is:

      Error: Parameter 'require' is already set on Package[pip] by #<Puppet::Resource::Type:0x005570c96bc260> at /home/branan/.puppetlabs/etc/code/environments/production/modules/foo/manifests/init.pp:4; cannot redefine at /home/branan/.puppetlabs/etc/code/environments/production/site.pp:1 on node rycon.delivery.puppetlabs.net
      

      This was discovered while Ops was trying to upgrade to a pre-release hoyt build.

      See the attached tarball for a minimal reproduction. This is an environment that can be untarred into a code dir and verified with puppet apply --debug --noop $CODEDIR/environments/repro/site.pp. The error only occurs when the resource override is in place. If the overridden parameters are inlined into the resource declaration, it works as expected.

      This was apparently introduced as part of PUP-7484, and is in general related to the PUP-25 work.

      According to a bisect, the breaking commit is 38413cd78c61fe34d2ee343ef773a07b4786f65a

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              branan Branan Riley
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Zendesk Support