feat: make default Slurm account configurable#109
Merged
Conversation
Persist the NeSI project code entered during `rjm_config` into the new `[SLURM] account` config key and have `GlobusComputeSlurmRunner` inject it as `sbatch --account=<account>` at submit time. If the user's Slurm script already specifies an account via `#SBATCH --account=...` or `#SBATCH -A ...`, the script value still wins. The key is optional, so existing configs and non-NeSI Slurm sites are unaffected.
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.
Summary
[SLURM] accountconfig key.rjm_confignow persists the NeSI project code entered at the prompt into this key when the Globus stack is configured (and skips it on--ssh).GlobusComputeSlurmRunnerreads the new key and passes it through to the remotesubmit_slurm_jobhelper, which injects--account="<account>"into thesbatchcommand line.#SBATCH --account=...or#SBATCH -A ..., the script wins and RJM does not add--accountto the command. The key is optional, so existing configs and non-NeSI Slurm sites keep working unchanged.docs/configuration.rstdocumenting the persistence, injection, and precedence rules.Test plan
pytest(full suite passes locally, 67 tests).submit_slurm_jobcases (no account configured, account injected, script already specifies via long form, script already specifies via short form) plus runner-init parsing (missing / whitespace / set).make htmlindocs/succeeds with no new warnings.rjm_configagainst a real NeSI account to confirm the value lands inrjm_config.iniand is picked up byrjm_batch_submit.