Repository navigation
feat: add lifecycle planning command over usage reports - #34
Merged
Merged
Conversation
Add `eb-keep-logs lifecycle` to classify installed modules into keep, warn, forbid-after, and candidate-remove from `usage --json` output and a TOML policy, emit Lmod `.modulerc.lua` warnings and forbids without deleting files, require a minimum observation window, and check installed dependents with `eb-stack rebuild-set`.
Add the lifecycle JSON Schema, CLI reference documentation, schema validation check, README summary, and a Diataxis how-to guide for planning reversible module deprecations.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I added
eb-keep-logs lifecycleto turneb-keep-logs usage --jsonreports into a reviewable software deprecation plan and an Lmod (Lua-based environment module system).modulerc.luafile.Sites running EasyBuild and the European Environment for Scientific Software Installations (EESSI) need a safe way to warn users and phase out stale modules without deleting installations blindly. This command reads a Tom's Obvious Minimal Language (TOML) policy file and classifies every installed module into
keep,warn,forbid-after, orcandidate-remove. It never deletes software directories, modulefiles, or logs.Before allowing
candidate-remove, the command enforces two safeguards. First, the input JavaScript Object Notation (JSON) report fromusagemust carry a--sinceboundary covering at leastmin_observation_daysup to the reference time (--noworEB_KEEP_LOGS_NOW). Second, candidate removals are checked against installed reverse dependents by invokingeb-stack rebuild-setas a subprocess (via--easyconfigs, or by reading a precomputed--rebuild-setJSON report). Modules with installed dependents or missing easyconfigs are held back fromcandidate-remove; modules with installed dependents stay inwarnwithout aforbiddirective so dependent modules continue to load.When
--modulerc-outis passed, the command writes the generated.modulerc.luawarnings and forbids durably via a temporary file and rename. Those forbids useforbid{}withafterdates in Coordinated Universal Time andnearly_messagenotices, plushide_version()on confirmed removal candidates. Passing--jsonemits one schema-validated JSON document (schema_version1). I also added thelifecycleJSON Schema. I updated the Command-Line Interface (CLI) reference andCOMPAT.md, and wrote a Diátaxis how-to guide. Regression tests compare existing command output to the output from before this command.