Skip to content

Commit 6b66d82

Browse files
authored
Merge branch 'canary' into bgw/worker-threads-version-check
2 parents 4954704 + 1380926 commit 6b66d82

376 files changed

Lines changed: 11740 additions & 6674 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agents/skills/pr-status-triage/SKILL.md

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,21 +14,24 @@ Use this skill when the user asks about PR status, CI failures, or review commen
1414

1515
## Workflow
1616

17-
1. Run `node scripts/pr-status.js` (or `node scripts/pr-status.js <number>`).
18-
2. Read generated files in `scripts/pr-status/`.
17+
1. Run `node scripts/pr-status.js --wait` in the background (timeout 1 min), then read `scripts/pr-status/index.md`.
18+
2. Analyze each `job-{id}.md` and `thread-{N}.md` file for failures and review feedback.
1919
3. Prioritize blocking jobs first: build, lint, types, then test jobs.
2020
4. Treat failures as real until disproven; check the "Known Flaky Tests" section before calling anything flaky.
2121
5. Reproduce locally with the same mode and env vars as CI.
2222
6. After addressing review comments, reply to the thread describing what was done, then resolve it. See `thread-N.md` files for ready-to-use commands.
23+
7. When the only remaining failures are known flaky tests and no code changes are needed, retrigger the failing CI jobs with `gh run rerun <run-id> --failed`. Then wait 5 minutes and go back to step 1. Repeat this loop up to 5 times.
2324

2425
## Quick Commands
2526

2627
```bash
27-
node scripts/pr-status.js
28-
node scripts/pr-status.js <number>
28+
node scripts/pr-status.js # current branch PR
29+
node scripts/pr-status.js <number> # specific PR
30+
node scripts/pr-status.js [PR] --wait # background mode, waits for CI to finish
31+
node scripts/pr-status.js --skip-flaky-check # skip flaky test detection
2932
```
3033

31-
## Detailed References
34+
## References
3235

33-
- [workflow.md](./workflow.md) - prioritization and common failure patterns
34-
- [local-repro.md](./local-repro.md) - mode/env matching and isolation guidance
36+
- [workflow.md](./workflow.md) prioritization, common failure patterns, resolving review threads
37+
- [local-repro.md](./local-repro.md) mode/env matching and isolation guidance

.agents/skills/pr-status-triage/local-repro.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,17 @@
77

88
## Match CI Environment Variables
99

10-
Read the job environment variables from `pr-status` output and mirror them locally.
10+
Read the "Job Environment Variables" section in `index.md` and mirror them locally. Key variables:
1111

12-
Key variables to watch:
12+
- `IS_WEBPACK_TEST=1` — forces webpack mode (turbopack is default locally).
13+
- `NEXT_SKIP_ISOLATE=1` — skips package isolation; **never use** when verifying module resolution or build-time compilation fixes.
14+
- Feature flags like `__NEXT_USE_NODE_STREAMS=true`, `__NEXT_CACHE_COMPONENTS=true` change DefinePlugin replacements.
1315

14-
- `IS_WEBPACK_TEST=1` forces webpack mode.
15-
- `NEXT_SKIP_ISOLATE=1` skips package isolation and can hide module-resolution issues.
16+
Example: a failure in "test node streams prod" needs:
17+
18+
```bash
19+
IS_WEBPACK_TEST=1 __NEXT_USE_NODE_STREAMS=true __NEXT_CACHE_COMPONENTS=true NEXT_TEST_MODE=start
20+
```
1621

1722
## Isolation Rule
1823

.agents/skills/pr-status-triage/workflow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
## Resolving Review Threads
3030

31-
After addressing a review comment (e.g., making the requested code change):
31+
After addressing a review comment (e.g., making the requested code change), or when you detect the current code already addresses it:
3232

3333
1. Reply to the thread describing what action was taken:
3434
```bash

0 commit comments

Comments
 (0)