Label integration→main PR when snapshot auto-recovery updates snapshots#606
Merged
Conversation
Agent-Logs-Url: https://github.com/rockcarver/frodo-cli/sessions/785c4a92-f59d-43b8-850f-044d533d3e97 Co-authored-by: vscheuber <28791378+vscheuber@users.noreply.github.com>
Agent-Logs-Url: https://github.com/rockcarver/frodo-cli/sessions/785c4a92-f59d-43b8-850f-044d533d3e97 Co-authored-by: vscheuber <28791378+vscheuber@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add label for integration PR on snapshot auto-recovery
Label integration→main PR when snapshot auto-recovery updates snapshots
Apr 20, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
Adds targeted labeling to the integration-batch automation so the generated integration -> main PR is labeled for snapshot review only when snapshot auto-recovery actually updated snapshot files.
Changes:
- Capture the generated
integration -> mainPR number as a step output inintegration-batch.yml. - Add a follow-up workflow step that conditionally applies
integration-needs-snapshot-reviewwhensteps.merge.outputs.snapshot_updates.filesis non-empty. - Document the new label in
docs/INTEGRATION.md.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
.github/workflows/integration-batch.yml |
Emits the integration PR number and conditionally applies the snapshot-review label based on snapshot_updates.files. |
docs/INTEGRATION.md |
Documents the new integration-needs-snapshot-review label and when it’s applied. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Adds targeted labeling for integration PRs that include snapshot auto-recovery changes. The workflow now applies
integration-needs-snapshot-reviewonly when snapshot files were actually updated, without changing PR selection or any other batching behavior.Workflow update (
.github/workflows/integration-batch.yml)integration -> mainPR number from the create/update step.steps.merge.outputs.snapshot_updatessnapshot_updates.fileslengthintegration-needs-snapshot-reviewonly when length > 0Scope guardrails preserved
Docs update (
docs/INTEGRATION.md)integration-needs-snapshot-reviewin the integration workflow label list.Original prompt
Create a PR in
rockcarver/frodo-clito label the generated integration PR when snapshot auto-recovery occurred.Decision:
Requirements:
integration-needs-snapshot-review..github/workflows/integration-batch.ymlso that after the integration PR is created/updated, if the batch summary indicates snapshot files were updated (non-empty list), add the label to the integration PR.Deliverable: Open a PR implementing this label behavior.
The following is the prior conversation context from the user's chat exploration (may be truncated):
User: OK, let's keep the current PR selection in place. Only green PRs are selected. But let's add the full test run (except for dry-run, then don't run the tests as they run for a long time).
Assistant: Yes—this makes sense and is low-risk: keep selection strict (only green PRs), and add a post-merge full test gate for real (non-dry-run) batching so you know
integrationis actually ready to PR intomain.I can’t open the PR from here in this turn, but here’s the concrete change I’d make (so you can implement quickly, and I’ll package it as a PR when I have write automation again).
What to add to
integration-batch.yml1) Add a “Full test on integration (non-dry-run only)” step at the end
Place it after:
integration(if the workflow does that before summaries/labels)Gate it with the workflow’s dry-run flag, e.g.:
if: inputs.dry-run != 'true'(or whatever your workflow uses)2) Ensure
frodois available (same approach you validated)Because your tests shell out to
frodo, ensure the job does:Notes:
package.json,npm testmaps tonpm run test:only, sonpm testis fine and keeps it conventional.3) (Optional but helpful) Step summary
Append a short section to
$GITHUB_STEP_SUMMARY, e.g.:That makes it obvious to maintainers scanning the run.
Why this is the right tradeoff
Two small clarifying questions (so the final PR is perfect)
dry-run,dry_run, or something else? (Just the exact key.)integration(so a failing batch doesn’t update the branch), or is it acceptable to push and let the run fail (so you can inspect the integration branch state)?If you answer those, I’ll give you the exact YAML snippet tailored to your workflow’s current structure.
User: @copilot Accepted Confirmation: Confirm agent session
Assistant: I’ll add that full integration-branch test gate while keeping PR selection strict (only green PRs), and I’ll make sure it’s skipped for dry-runs.
I’m not able to push the change from this message, but the exact design is:
Workflow behavior change
After the batch merge work finishes (including any snapshot auto-updates and lockfile regeneration), add a final step:
What the step should run (non-dry-run only)
Because your tests shell out to
frodo, the step should ensure the CLI is available first (same approach that already worked for snapshot updates):npm cinpm run build:onlynpm i -gnpm test(which in this repo maps to the full Jest run)Why this is the right approach
mainby ensuring integration is green as a combined set before an integration PR is opened/merged.One decision to make (so I implement it exactly as you want)
Do you want the workflow to:
integrationbranch (so a failing batch never updates the branch), orTell me which you prefer, and I’ll align the cha...
This pull request was created from Copilot chat.