feat(sources): use rpmdev-bumpspec for release updates - #349
Open
Thien Trung Vuong (trungams) wants to merge 3 commits into
Open
feat(sources): use rpmdev-bumpspec for release updates#349Thien Trung Vuong (trungams) wants to merge 3 commits into
Thien Trung Vuong (trungams) wants to merge 3 commits into
Conversation
Keep rpmdev-bumpspec external while providing one deterministic host operation for release updates. The runner isolates user-specific state, forwards the effective RPM context, and validates each mutation by comparing structured source EVRs with the host RPM implementation. Treat every operation as a transaction: command, parsing, identity, and ordering failures restore the original spec bytes. Focused in-memory tests cover runtime discovery, sidecar context, build macros, target propagation, strict output contracts, RPM ordering, and rollback.
Keep fingerprint-derived synthetic changes as the source of N while delegating non-autorelease Release and changelog updates to the transactional rpmdev-bumpspec runner. Build, render, and prepare-sources share the same host operation and available build target context. Remove the custom static-integer parser and release-tag overlay. Each requested bump must produce a strictly newer source Release, and any failed operation restores the complete pre-sequence spec while existing manual and autorelease modes remain unchanged.
Describe the tested host rpmdev-bumpspec workflow, fixed transitional changelog metadata, and strict source-EVR acceptance checks. Clarify that conditional and fallback forms are attempted natively but ineffective mutations fail and restore the original spec. Keep emitted component guidance and configuration comments aligned with the implementation while documenting the existing manual and autorelease exceptions and the prepare-sources opt-out.
Copilot started reviewing on behalf of
Thien Trung Vuong (trungams)
September 9, 2026 19:34
View session
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
An unresolved moderate issue can override an explicit dist macro and invalidate release-bump verification.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR replaces static release arithmetic with host-side rpmdev-bumpspec operations, RPM EVR validation, and rollback support.
Changes:
- Integrates bumpspec release updates into render, source preparation, and build flows.
- Adds tests for execution, validation, rollback, and release modes.
- Updates documentation and agent guidance.
File summaries
| File | Summary |
|---|---|
internal/projectconfig/component.go |
Updates release-mode documentation. |
internal/app/azldev/core/sources/sourceprep.go |
Adds bumpspec configuration and integration. |
internal/app/azldev/core/sources/release.go |
Applies transactional release bumps. |
internal/app/azldev/core/sources/release_test.go |
Removes obsolete arithmetic tests. |
internal/app/azldev/core/sources/release_internal_test.go |
Tests release modes and rollback. |
internal/app/azldev/core/sources/bumpspec.go |
Executes and validates bumpspec operations; moderate issue (2 votes): dist %{nil} can override an explicit build.defines.dist. |
internal/app/azldev/core/sources/bumpspec_internal_test.go |
Tests bumpspec execution and EVR handling. |
internal/app/azldev/cmds/component/render.go |
Wires bumpspec into rendering. |
internal/app/azldev/cmds/component/preparesources.go |
Wires bumpspec into source preparation. |
internal/app/azldev/cmds/component/build.go |
Passes architecture and macros to release handling. |
internal/app/azldev/agentskill/content/comp-toml.md.tmpl |
Updates release configuration guidance. |
internal/app/azldev/agentskill/content/build-component.md.tmpl |
Documents bumpspec behavior and troubleshooting. |
internal/app/azldev/agentskill/agentskill_test.go |
Validates generated guidance. |
docs/user/reference/config/components.md |
Documents bumpspec requirements and behavior. |
Review details
- Files reviewed: 14/14 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
+261
to
+266
| args := append(rpmdevBumpspecContextArgs(request), | ||
| "-q", "--srpm", | ||
| "--define", "dist %{nil}", | ||
| "--qf", rpmdevBumpspecEVRQueryFormat, | ||
| request.SpecPath, | ||
| ) |
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.
Introduce
rpmdev-bumpspecinto the current static release bump logic. The existing bump count and synthetic history remain unchanged and will be updated with follow-up PRs with lock files removal/changelog generation rework.For every
rpmdev-bumpspecinvocation, we verify the bump by evaluating the source package EVR before and after the operation and requiring theReleasefield to strictly increase according to RPM ordering.