Skip to content

Pin puppet_litmus unconditionally; drop the no-token litmus 1.x fallback - #633

Open
amitkarsale wants to merge 1 commit into
mainfrom
fix/litmus-forge-token-fallback
Open

Pin puppet_litmus unconditionally; drop the no-token litmus 1.x fallback#633
amitkarsale wants to merge 1 commit into
mainfrom
fix/litmus-forge-token-fallback

Conversation

@amitkarsale

Copy link
Copy Markdown
Contributor

Why

Mend's CI-upload scan for this repo (puppet_modules product in the CVE
remediation hub) resolves Gemfile without PUPPET_FORGE_TOKEN set, so
it walks the if ENV["PUPPET_FORGE_TOKEN"].to_s.empty? branch and reports
ancient puppet_litmus 1.x (and its stale transitive deps, e.g. old
bolt/jwt) as the real dependency tree — inflating CVE counts for a version
nobody actually tests with. A normal bundle install (which does have the
token, e.g. in this repo's own CI) resolves puppet_litmus 2.x fine.

Raised in https://perforce.slack.com/archives/C0BHQDASRRA/p1788771803282819.
Same root cause and fix puppet_agent already applied in
PA-7824.

What

  • Gemfile: drop the token-gated fallback, pin puppet_litmus unconditionally
    to the version already used on the "token present" branch.
  • .sync.yml: add the matching Gemfile: overrides: entry so a future
    pdk update doesn't regenerate the fallback from the shared pdk-templates
    default (this is the same mechanism already used in modules that don't have
    this bug, e.g. puppetlabs-stdlib).

Test plan

  • CI green (bundle install / rubocop / spec)

Mend's CI-upload scan resolves this Gemfile without PUPPET_FORGE_TOKEN set,
so it walks the `if ENV["PUPPET_FORGE_TOKEN"].to_s.empty?` branch and reports
ancient litmus 1.x (and its old transitive deps) as the real dependency tree,
even though every real bundle install (which has the token) resolves current
litmus 2.x. Same root cause and fix puppet_agent applied in PA-7824
(puppetlabs/puppetlabs-puppet_agent@7b8e24e):
drop the token-gated fallback and pin unconditionally. .sync.yml override
added so a future `pdk update` doesn't regenerate the fallback from the
shared pdk-templates default.

Co-Authored-By: WOZCODE <contact@withwoz.com>
@amitkarsale
amitkarsale requested review from a team and bastelfreak as code owners September 10, 2026 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant