Conversation
…erministic scripts
.github/workflows/reference-impl-sync.md
- Replace vague "Follow the prompt" instruction in the issue body template
with explicit mandates: read the prompt file in full, do not clone the
reference implementation manually, do not update .lastmerge manually,
do not skip the finish script.
.github/workflows/build-test.yml
- Add "Validate reference-impl-sync completeness" step to the java-sdk job.
Only runs on PRs labeled reference-impl-sync.
- Check 1: .lastmerge must appear in the PR diff (proves finish script ran).
- Check 2: if scripts/codegen/ changed, src/generated/java/ must also have
changed (proves codegen ran when the schema version was bumped).
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds workflow-level guardrails to make “reference implementation sync” PRs more deterministic and harder for automation to partially complete (e.g., skipping finish scripts or codegen).
Changes:
- Tighten the reference-impl-sync issue template instructions to explicitly forbid manual steps and skipping the finish script.
- Add a CI validation step (only for PRs labeled
reference-impl-sync) to enforce that.lastmergeand generated code changes are present when expected.
Show a summary per file
| File | Description |
|---|---|
.github/workflows/reference-impl-sync.md |
Strengthens the issue body “Instructions” section to mandate using the prompt + scripts and prohibit manual cloning/.lastmerge edits. |
.github/workflows/build-test.yml |
Adds a labeled-PR-only step to validate that the finish script and (when applicable) codegen ran by checking for expected diff contents. |
Copilot's findings
- Files reviewed: 2/2 changed files
- Comments generated: 3
| CHANGED=$(git diff --name-only origin/main...HEAD) | ||
|
|
||
| # 1. .lastmerge must be updated (proves finish script ran) | ||
| if echo "$CHANGED" | grep -q '^\\.lastmerge$'; then |
| github.event_name == 'pull_request' && | ||
| contains(github.event.pull_request.labels.*.name, 'reference-impl-sync') | ||
| run: | | ||
| git fetch origin main --depth=1 |
|
|
||
| ❌❌Do NOT clone the reference implementation manually — the start script does this.❌❌ | ||
| ❌❌Do NOT update .lastmerge manually — the finish script does this.❌❌ | ||
| ❌❌Do NOT skip the finish script — it syncs codegen versions and updates .lastmerge.❌❌ |
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.
.github/workflows/reference-impl-sync.md
.github/workflows/build-test.yml