Uploaded image for project: 'CFEngine Community'
  1. CFEngine Community
  2. CFE-2045

Result classes are not defined in update packages promises when the package is already up to date

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: Medium
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.6.7
    • Component/s: Promise type: packages
    • Labels:
      None

      Description

      When using a package promise with update action, and giving a minimum version, the result classes are not defined if the package is up to date.

      <pre>
      "my_package"
      package_policy => "update",
      package_method => apt,
      package_select => ">=",
      package_version => "3.0.5",
      classes => kept_if_else("debian_install_kept_my_package", "debian_installed_my_package", "debian_install_failed_my_package")

      body classes kept_if_else(kept, yes,no)
      {
      promise_kept => { "${kept}" };
      promise_repaired => { "${yes}" };
      repair_failed => { "${no}" };
      repair_denied => { "${no}" };
      repair_timeout => { "${no}" };
      }
      </pre>

      The verbose output is only :
      <pre>
      Installed package is up to date, not updating
      </pre>

      And no classes are defined.

        Attachments

          Activity

            People

            Assignee:
            a10040 Kristian Amlie
            Reporter:
            amousset Alexis Mousset
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: