Conversation
* Add projection injection module
* Add requirements for injection modules
* Add tests for injection projection module, and inputs/requirements
* Add prerelease injection module
* Add tests for prerelease injection module
* Run injection.projection and injection.prerelease modules
* deploy-1-setup: Remove projection checks
* Remove unneeded mergedeep requirement
* Add module inits to folders
* Add step for installing dependencies, update names for checkout steps
* Used cd module prefix rather than custom working-directory so we can find the manifest
* Added required input for prerelease modification, always print out updated manifest at end
* Add back EOT
* Update non-root-spec projections to namespaced `{name}/prX-Y/VERSION` format
* Updated tests for namespaced non-root-spec projections
* Update prerelease module argument from --root-spec-version to --version
* Pass in sys.argv to parse_args, add tests
* Refactor workflow to split generation of root spec and packages
* Rename projections script to modules
* Add inject_includes function
* For test inputs, comment what is expected
* Reordered functions
* Updated tests after code updates
* Apply suggestions from code review
Co-authored-by: Aidan Heerdegen <[email protected]>
Signed-off-by: Tommy Gatti <[email protected]>
* Add root_spec to includes set, but remove it later when alphabetically sorting the includelist since it always comes first
* Updated output of manifest
* Ran black
* Added getter module for accessing various parts of a spack manifest
* Update `[test_]modules.py` to use new getter module
* Update `[test_]prerelease.py` to use getter module, update deploy-2-start to remove --root-spec arg
* Ran black again
* Raise NotImplementedErrors, add comments for successful matches
* Remove comments of old code
* Apply suggestions from code review
Co-authored-by: Aidan Heerdegen <[email protected]>
Signed-off-by: Tommy Gatti <[email protected]>
* Add example to multi-target spec to test function
* Parameterized tests
* Fixes following more test cases
* Converted manifest with no packages to fixture
* Improved from_file classmethod tests
* Parameterized valid and mistakenly invalid tests
* Remove `root-spec` arg and instead get from manifest directly, update tests
* Add new prerelease script flag `--keep-root-spec-intact`, that doesn't remove version information
---------
Signed-off-by: Tommy Gatti <[email protected]>
Co-authored-by: Aidan Heerdegen <[email protected]>
* Validate MDR config/packages.json
* Pass info from MDR config/packages.json to module injection script
* Update variable name to `vars.CONFIG_PACKAGES_SCHEMA_VERSION`
* Change cwd relative to build-cd rather than model for scripts
* Add output of packages to be injected/added to provenance DB
* Update prerelease projection to `ROOT_SPEC/prX-Y/{name}/VERSION`
* Update tests for new prerelease injection logic
|
@aidanheerdegen I've updated this branch with the projection fixes required |
|
Current pre-release module projections have been modified to use a namespace approach, putting all the dependent modules under a single namespace of the pre-release environment to make them easier to reliably remove when a PR is closed. The current approach is to use module names like: but this is flawed because One solution would be to put the dependent modules in a hidden subdirectory, e.g. It's slightly messier, but would allow an |
|
We ended up going with |
aidanheerdegen
left a comment
There was a problem hiding this comment.
LGTM. Just a question about cd cd.
References #311
Background
Since we seem to have a tradition of bundling major-level changes into one PR, we have a few updates that will take us from
v5tov6, namely:varsto File-Based Special Packages #305vars#310As well as a few bug fixes along the way.
Testing
Testing details for each PR is in the linked PR.
Unit Tests
Unit tests can be run with
python3 -m pytest, all of them succeeded.E2E Tests
Tested in ACCESS-NRI/ACCESS-TEST#52 using the
dev-v6_TEST, as well as ACCESS-NRI/ACCESS-TEST#53Test manifests with existing projections
Tested in https://github.com/ACCESS-NRI/ACCESS-TEST/actions/runs/16611404535, using this
packages.jsonand this manifest. It led to this injection: https://github.com/ACCESS-NRI/ACCESS-TEST/actions/runs/16611404535/job/46995084145#step:11:40Test manifests with no projections
Tested in https://github.com/ACCESS-NRI/ACCESS-TEST/actions/runs/16611534408, using the same
packages.jsonand this manifest. It led to this injection: https://github.com/ACCESS-NRI/ACCESS-TEST/actions/runs/16611534408/job/46995451420?pr=52#step:11:40