Skip to content

Preserve sticky module requirements during purge - #693

Open
adrien-cotte wants to merge 1 commit into
envmodules:mainfrom
adrien-cotte:fix/sticky_prereq_purge
Open

Preserve sticky module requirements during purge#693
adrien-cotte wants to merge 1 commit into
envmodules:mainfrom
adrien-cotte:fix/sticky_prereq_purge

Conversation

@adrien-cotte

Copy link
Copy Markdown
Contributor

Purge skips sticky and super-sticky modules but still attempts to unload their non-sticky requirements. This reports an unrelated dependency error without explaining why the requirement remains loaded.

Preserve requirements needed by retained sticky modules and apply the sticky_purge reporting mode to their skipped unload.

Fixes #582

Assisted-by: Codex:gpt-5.6-sol

Comment thread tcl/report.tcl.in Outdated
}

proc getStickyReqUnloadMsg {{tag sticky}} {
return "Unload skipped because module is required by a $tag module"

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use a shorter message structure: Unload of $tag module requirement skipped

@xdelaruelle xdelaruelle left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testsuite should be fixed as CI jobs are failing.

Documentation should be adapted to mention this behavior change, especially in module.rst, changes.rst, the sticky/module-tags design docs and the sticky-modules cookbook.

Also good to check if this has an impact on other stuff mentioning sticky modules like stash-environment, initial-environment, conflict_unload, evaluation-errors. Check these design doc and adapt them if required.

@adrien-cotte
adrien-cotte force-pushed the fix/sticky_prereq_purge branch from 2f4a98e to 18f8719 Compare September 9, 2026 09:02
Purge skips sticky and super-sticky modules but still attempts to unload
their non-sticky requirements. This reports an unrelated dependency error
without explaining why the requirement remains loaded.

Preserve requirements needed by retained sticky modules and apply the
sticky_purge reporting mode to their skipped unload.

Fixes envmodules#582

Assisted-by: Codex:gpt-5.6-sol Codex:gpt-6-astra
Signed-off-by: Adrien Cotte <adrien.cotte@asplus.fr>
@adrien-cotte
adrien-cotte force-pushed the fix/sticky_prereq_purge branch from 18f8719 to 4d70791 Compare September 9, 2026 12:45
@codecov

codecov Bot commented Sep 9, 2026

Copy link
Copy Markdown

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

ℹ️ You can also turn on project coverage checks and project coverage reporting on Pull Request comment

Thanks for integrating Codecov - We've got you covered ☂️

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.

Silent purge fails when super-sticky module prerequisite isn't super-sticky

2 participants