saltstack / saltstack/salt

[BUG] pkg.installed doesn't show version changes in testmode

Open
#66,848 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug needs-triage
Dominant language
Python
Stars
15.7k
Forks
5.6k
Avg merge
2d 44m
Merged PRs (30d)
80

Description

Description
When running salt-master/salt-minion 3002 in testmode the changes would show the exact version that would be installed:

----------
          ID: openjdk-17-jdk
    Function: pkg.installed
      Result: None
     Comment: The following packages would be installed/updated: openjdk-17-jdk-headless=17.0.*
     Started: 18:24:48.328977
    Duration: 42.484 ms
     Changes:

But with salt-minion starting at least 3004.2 or currently salt-master/salt-minion 3006.9 it wont show the version:

----------
          ID: openjdk-17-jdk
    Function: pkg.installed
      Result: None
     Comment: The following packages would be installed/updated: openjdk-17-jdk-headless
     Started: 17:29:26.049897
    Duration: 86.968 ms
     Changes:
              ----------
              openjdk-17-jdk-headless:
                  ----------
                  new:
                      installed
                  old:

There is an issue related to that but it only mentions new package installs: https://github.com/saltstack/salt/issues/63985

I'm not sure if there was a change between 3002 and 3004. There are a lot of possibilities using different version for minion and master. I'm not able to setup all combinations to narrow it down atm.

What i'm sure of is that there is a regression for pkg.installed in testmode somewhere after release 3002.

So my only questions is: Is this known and does version 3007 fix that?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce pkg.installed in testmode with openjdk-17-jdk across Salt 3002, 3004.2, and 3006.9, comparing the reported package changes. Trace the regression between those versions and verify that the proposed fix reports the exact version for updates as well as new installs.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
devops, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.