Y stream handling by inheritance - #788
Conversation
Collect deterministic Jira clone, fixVersion, and Fixed in Build metadata for Important and Critical Y-stream CVEs. Preserve existing eligibility behavior when shipped clones have no usable NVR and keep lower severities out of the inheritance fast path. Assisted-by: Codex
Carry shipped candidates into the backport workflow, validate Brew source provenance, select same-major builds with matching Epoch:Version, and find the exact single-issue commit across diverged histories. Add authenticated tools to fetch full commit SHAs into namespaced refs and read exact remote branch heads. Assisted-by: Codex
Validate the selected packaging commit, materialize patch files directly from their Git blobs, and expose the source spec diff for guided adaptation. Audit that inherited patches remain exact and active while protected spec metadata and unrelated files stay untouched. Assisted-by: Codex
Use a restricted LLM to map a validated Z-stream spec change onto Y-stream without changing inherited patch blobs. Audit the result, add deterministic release and changelog bookkeeping, validate the package, and fall back durably to normal backporting when an unchanged patch cannot apply. Publish inherited changes through checkpointed commit, push, and merge-request phases. Assisted-by: Codex
Describe candidate metadata, deterministic validation and fallback, publication boundaries, consolidation compatibility, and the Brew-controlled source trust path. Assisted-by: Codex
PR Summary by QodoInherit shipped Z-stream fixes in Y-stream CVE backports
AI Description
Diagram
High-Level Assessment
Files changed (23)
|
Code Review by Qodo
1.
|
Summary
Add a Y-stream inheritance fast path for Important and Critical CVEs so the backport agent can reuse a shipped Z-stream packaging fix instead of rediscovering the patch from scratch.
When triage sees an Important/Critical Y-stream CVE with at least one shipped Z-stream clone, it now carries that clone’s Jira key, Fixed in Build NVR, and fixVersions in the backport task. The backport agent may then:
gitlab.com/redhat/rhel/rpms/<package>#<full-sha>sourceResolves:commit in the diverged Z-stream historycXs(no shell, network, or file-creation tools)%prepusage%prep, SRPM, and Copr before commit/push/MRIf inheritance cannot be applied safely, the existing backport path runs unchanged. An already-present fix is a terminal error, not an empty success. After a validated commit is pushed, retries resume at MR creation only (same
ymir_backportlabel and consolidation queue).Why
Y-stream Important/Critical CVEs often already have a shipped Z-stream fix for the same upstream tarball. Re-running the full LLM backport duplicates that work and can produce a different patch. This path prefers the shipped evidence when the packaging commit is simple enough to inherit.