-
Notifications
You must be signed in to change notification settings - Fork 3k
ci(autofix): recover from generated-artifact CI gates and stop silent stalls #6998
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
5f6da4d
ci(autofix): teach the review loop about generated-artifact gates and…
ee76efb
ci(autofix): drop comment-trigger and raw-log injection; keep them wi…
789611a
ci(autofix): address review — handle cancellation, fold a PR fetch, c…
414d12c
ci(autofix): fix handoff/staleness design flaws from review (4 critic…
84b2ffb
ci(autofix): address review nits — symmetric schema-gate outcome, sof…
14dae37
ci(autofix): close review edge cases — structural schema gate, immuta…
43e4707
test(autofix): assert regression-catching invariants flagged in review
f3cf288
ci(autofix): fix iconv silent-abort, fold branch fetch, tighten stale…
808fbad
ci(autofix): review round — skip empty branch, hoist staleness vars, …
1acbd08
ci(autofix): DRY schema check via --check, widen handoff detail, hone…
6e39e43
ci(autofix): revert schema gate off --check (removed from main by #70…
05b2f27
ci(autofix): set outcome=failed explicitly if the schema generator cr…
645d683
ci(autofix): extract the settings-schema gate into a shared script
00c2fed
Merge branch 'main' into feat/autofix-generated-artifact-loop
wenshao a187d00
test(autofix): update verify-gate assertions for the extracted schema…
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| #!/usr/bin/env bash | ||
| # Settings-schema freshness gate, shared by the qwen-autofix verify steps | ||
| # (.github/workflows/qwen-autofix.yml) so the two gates cannot drift apart. | ||
| # | ||
| # Mirrors CI's "Check settings schema is up-to-date" step EXACTLY: regenerate, | ||
| # then fail if the committed artifact changed. Uses regenerate + | ||
| # `git status --porcelain` (NOT the generator's --check, which was reverted | ||
| # from main by #7031 — after merge this runs against main's generator, which | ||
| # ignores args and would make --check fail-open). Stale schemas are invisible | ||
| # to build/typecheck/lint/vitest. | ||
| # | ||
| # On failure: prints the diff, restores the schema file, writes | ||
| # `outcome=failed` to $GITHUB_OUTPUT (when set, matching the calling step's | ||
| # contract), and exits 1. | ||
| set -uo pipefail | ||
|
|
||
| SCHEMA_FILE='packages/vscode-ide-companion/schemas/settings.schema.json' | ||
|
|
||
| fail() { | ||
| if [[ -n "${GITHUB_OUTPUT:-}" ]]; then | ||
| echo "outcome=failed" >> "${GITHUB_OUTPUT}" | ||
| fi | ||
| exit 1 | ||
| } | ||
|
|
||
| # Guard the generator itself: if it CRASHES (e.g. a type error the agent | ||
| # introduced in the schema source), a caller running under set -eo pipefail | ||
| # would abort before outcome=failed is written, leaving OUTCOME unset. Handle | ||
| # it here so the failure is explicit, not inferred from job.status. | ||
| if ! npm run generate:settings-schema; then | ||
| echo "❌ Settings schema generator failed to run." | ||
| fail | ||
| fi | ||
|
|
||
| if [[ -n "$(git status --porcelain "${SCHEMA_FILE}")" ]]; then | ||
| echo "❌ ${SCHEMA_FILE} is out of date. Run: npm run generate:settings-schema" | ||
| git --no-pager diff -- "${SCHEMA_FILE}" || true | ||
| git checkout -- "${SCHEMA_FILE}" || true | ||
| fail | ||
| fi |
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.