You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Make CLI and Ansible release tests configurable - #63
Release checks assume a fixed CLI inventory and require an Ansible collection regardless of which artifacts a release ships. RHTAS 1.5 replaces tuftool with tufcli and no longer publishes the model-transparency stack, Ansible collection, or client-server image.
What
Run shared CLI archive and executable checks inside each product suite, using cliStack.images YAML inventories. Include RHTAS 1.5 and Model Transparency defaults, plus a RHTAS 1.4 override.
Add rhtas.ansible.enabled to disable Ansible for the current 1.5 defaults and allow any future release to restore it. Older-stream examples explicitly enable it. Partial overrides retain the flag and image lists.
Preserve legacy client-server comparisons and skip that suite for RHTAS 1.5 and later.
Fail invalid CLI configuration and missing configured artifacts. Enabled Ansible checks continue to require the collection image.
Validated CLI archives from 1.5.0 and 1.4.3, Model Transparency defaults, the Ansible 1.5 skip, legacy collection loading, future re-enablement, configuration tests, acceptance-package compilation, and the CI-pinned linter.
Breaking changes
The standalone test/acceptance/cli_stack package is removed. Release CI must select the owning product suite and supply stream-specific inventories through TEST_CONFIG. Releases shipping Ansible must set rhtas.ansible.enabled: true to override the current defaults. The README documents the migration; the releases repository is unchanged.
The following are alternative approaches to this PR:
1. Central version-indexed inventory registry
➕ Keeps all release inventories in one source
➕ Could select inventories automatically from VERSION
➖ Couples product release schedules to shared test code
➖ Requires code changes whenever published inventory changes
➖ Makes explicit CI configuration less visible
2. Retain a standalone CLI suite
➕ Preserves existing CI package selection
➕ Keeps CLI checks isolated from other acceptance suites
➖ Continues treating unrelated products as one inventory
➖ Requires additional routing logic for product and stream selection
➖ Weakens ownership of republished CLI artifacts
Recommendation: Keep the PR's product-owned, YAML-configured approach. It aligns inventories with the suites responsible for publishing them, supports explicit stream overrides and empty inventories, and avoids hard-coding version policy into shared Go code.
Files changed (18) +607 / -10
Enhancement (2) +162 / -0
config.goLoad and validate product CLI inventories+101/-0
Load and validate product CLI inventories
• Introduces strict YAML decoding, product-specific inventory replacement, explicit disable support, and archive path and platform validation.
1. Older releases use wrong inventory 🔗 Cross-repo conflict≡ Correctness
Description
resolveTestConfig discards a documented top-level cliStack whenever it finds any wrapped product
mapping, while GetCLIStackConfig retains the embedded RHTAS 1.5 defaults unless the resulting
configuration contains an explicit rhtas.cliStack override. Mixed configurations and existing
pre-1.5 release configurations therefore check for tufcli-cli-stack-image instead of their
stream-specific archives, including the 1.4.3 snapshot that publishes tuftool-cli-stack-image and
model-transparency.
ⓘ Recommendations generated based on similar findings in past PRs
Evidence
The resolver explicitly skips cliStack while collecting wrapped product mappings and returns as
soon as any mapping is found, making its later handling of the unwrapped RHTAS section unreachable
for mixed files even though the README documents that form as applying to RHTAS independently of
other product sections. The overlay logic then replaces the embedded 1.5 inventory only when it
receives rhtas.cliStack; the releases workflow supplies the adjacent complete 1.4.3 configuration
without such a section, while that release snapshot contains tuftool and model-transparency rather
than the default tufcli image.
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution
## Issue description
Existing pre-1.5 release configurations that omit `rhtas.cliStack` inherit the incompatible embedded 1.5 inventory, and a documented top-level `cliStack` cannot correct it when the same `TEST_CONFIG` contains any product-wrapped section because the resolver discards the unwrapped RHTAS configuration. This prevents combined and stream-specific release configurations from supplying the intended RHTAS CLI inventory.
## Fix Focus Areas
- test/acceptance/rhtas/defaults.yaml[130-138]
- test/support/cli/config.go[41-54]
- testdata/testconfig-1.4.yaml[1-85]
- rhtas/rhtas-operator/1.4.3/stable/testingResources/structural-tests.yaml[1-84]
- test/support/config/config.go[39-58]
- test/support/cli/config_test.go[20-80]
## Recommended Fix
Update configuration resolution so that a top-level `cliStack` section is merged into the `rhtas` product map before parsed product sections are returned, while preserving an explicitly wrapped `rhtas.cliStack` as authoritative when both forms are present. Add a regression test with a wrapped non-RHTAS product and an unwrapped `cliStack`. Before enabling these tests in release CI, also add stream-specific `rhtas.cliStack` inventories to each affected releases-repository `testingResources/structural-tests.yaml`, using the 1.4 override for 1.4 releases and explicit empty inventories where checks should remain disabled; alternatively, make structural tests select compatible embedded inventories from `VERSION` when no release override exists.
ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools
2. CLI snapshots run all suites 🔗 Cross-repo conflict☼ Reliability
Description
Deleting the standalone test/acceptance/cli_stack package leaves the releases workflow’s
CLI_STACK package search with no match. When a dedicated CLI-stack snapshot triggers that path,
the workflow falls back to ./test/..., applying every product suite to a CLI-only snapshot and
causing unrelated acceptance failures.
ⓘ Recommendations generated based on similar findings in past PRs
Evidence
The PR explicitly removes the standalone suite and documents that releases CI must be migrated. The
pinned releases workflow still searches for a package containing cli_stack; because the deleted
package no longer appears in go list, its empty selection activates the workflow’s all-tests
fallback for the dedicated CLI-only snapshots.
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution
## Issue description
The releases workflow still selects the deleted standalone CLI-stack package and falls back to all tests when no package matches.
## Fix Focus Areas
- test/acceptance/cli_stack/cli_stack_acceptance_suite_test.go[12-15]
- README.md[109-114]
- .github/workflows/structural.yml[268-289]
## Recommended Fix
Coordinate this merge with a releases-repository workflow update that maps CLI-stack releases to the owning product suite and runs only its CLI-stack checks. Ensure the selected snapshot and `TEST_CONFIG` contain the complete product inventory required by that suite, and remove the obsolete standalone-package selection.
ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools
Review mode: 🧠 Deep: This is a broad, behavior-changing configuration and test refactor spanning multiple suites, parsing/validation paths, release overrides, archive checks, and version-dependent behavior, creating many independent opportunities for subtle defects.
Tip of the day
💡 Did you know, you can route each action level your way: inline, summary, both, or drop
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
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.
Why
Release checks assume a fixed CLI inventory and require an Ansible collection regardless of which artifacts a release ships. RHTAS 1.5 replaces tuftool with tufcli and no longer publishes the model-transparency stack, Ansible collection, or client-server image.
What
cliStack.imagesYAML inventories. Include RHTAS 1.5 and Model Transparency defaults, plus a RHTAS 1.4 override.rhtas.ansible.enabledto disable Ansible for the current 1.5 defaults and allow any future release to restore it. Older-stream examples explicitly enable it. Partial overrides retain the flag and image lists.Validated CLI archives from 1.5.0 and 1.4.3, Model Transparency defaults, the Ansible 1.5 skip, legacy collection loading, future re-enablement, configuration tests, acceptance-package compilation, and the CI-pinned linter.
Breaking changes
The standalone
test/acceptance/cli_stackpackage is removed. Release CI must select the owning product suite and supply stream-specific inventories throughTEST_CONFIG. Releases shipping Ansible must setrhtas.ansible.enabled: trueto override the current defaults. The README documents the migration; the releases repository is unchanged.