Skip to content

feat: changelog entries for devkit adoption PRs - #1407

Merged
c-vigo merged 3 commits into
devfrom
feature/1404-adoption-changelog-entries
Aug 10, 2026
Merged

c-vigo merged 3 commits into
devfrom
feature/1404-adoption-changelog-entries

Conversation

@c-vigo

@c-vigo c-vigo commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Summary

Adoption PRs opened by the devkit-upgrade workflow now get a CHANGELOG.md entry, exactly like Renovate PRs (option B from the design discussion on #1404):

  • vig-utils: renovate-changelog-pr branches on the PR title — chore: adopt devkit X.Y.Z[-rcN] produces - **Adopt vigOS devkit X.Y.Z** ([#PR](…)) — [release notes](…) at the top of ## Unreleased → ### Changed, via the existing insertion helper (dedup on the PR link). The body is never fed through the Renovate table parser. The CLI also no-ops instead of crashing when CHANGELOG.md is absent (trunk consumers).
  • Scaffold renovate-changelog-build.yml: the author filter accepts vigos-devkit-upgrade[bot] alongside renovate[bot]. Workflow names are deliberately unchanged (a workflow_run rename has a default-branch transition hazard). Devkit's own de-coupled copy (Migrate devkit-own sync-main-to-dev.yml off the container/resolve-image pattern #996) is untouched — devkit never receives adoption PRs.
  • renovate-changelog-commit.yml (root + manifest-derived scaffold): commit message generalized to docs(changelog): add unreleased entry for PR N.

rc → final force-updates wipe the changelog commit, but the resulting synchronize event re-runs the build (sender guard only excludes commit-action-bot[bot]), so the entry is re-added with the new version.

Verification

  • TDD: failing tests committed first (dbf2de14), implementation after (22ee7f27); 26/26 in test_renovate_changelog_pr.py
  • just precommit (all files), 666 pytest (vig-utils + transforms + scaffold lint/drift), 590 bats — all green
  • Insertion spike validated against commit-action's real CHANGELOG.md (clean insert, idempotent re-run)

Closes #1404

@c-vigo
c-vigo enabled auto-merge August 10, 2026 14:04
@c-vigo
c-vigo merged commit 46178bb into dev Aug 10, 2026
13 checks passed
@c-vigo
c-vigo deleted the feature/1404-adoption-changelog-entries branch August 10, 2026 14:06
c-vigo added a commit that referenced this pull request Aug 10, 2026
## Summary

The devkit-upgrade workflow no longer creates, reuses, or
garbage-collects a per-train adoption issue — adoption PRs become bot
PRs exactly like Renovate's, with the PR as the traceable artifact and
the changelog entry (#1404 / PR #1407) linking it.

Motivation (live evidence): on gitflow consumers the dev-targeted
`Closes #N` never auto-closes, so every train strands an open issue
(e.g. vig-os/commit-action#140, still open after its PR merged). The
#1347 cleanup step existed only to garbage-collect issues the workflow
itself created.

Changes in `assets/workspace/.github/workflows/devkit-upgrade.yml`:

- "Find or create the adoption issue" step and the entire #1347 no-diff
cleanup step removed — a no-diff run now strands nothing by construction
- Branch: `chore/devkit-<train-suffix>` (the branch guard explicitly
allows the issue-less `chore/<summary>` shape; still keyed on the train
so rc → final reuse the same branch/PR)
- Staging commit: `chore: adopt devkit X.Y.Z` with no `Refs:` line
(`chore` is exempt; hooks still validate in the project shell)
- PR body: links the devkit release notes instead of an auto-close
marker
- Token mint: `permission-issues: write` dropped (three-permission
least-privilege mint); preflight error message and header docstring
updated

## Rollout notes

- Takes effect one train after shipping (the workflow runs from the
consumer's base branch)
- One-time migration: close adoption issues left open by earlier trains
on the consumers (commit-action#140 et al.)

## Verification

- TDD: failing tests committed first (`880c7d32`), workflow refactor
after (`cf47f622`); 18/18 in `test_workflow_devkit_upgrade.py` incl. new
`test_no_adoption_issue_lifecycle` (no `gh issue`, no `Refs:`/auto-close
markers, chore-shape branch, release-notes link) and the tightened
least-privilege mint assertion
- `just precommit` (all files), 695 pytest (vig-utils +
workflow/scaffold/transform/model), full bats — all green
- `docs/issues/*.md` mentions of the old flow are frozen historical
records and deliberately untouched

Closes #1405
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant