home / skills / vercel / next.js / pr-status-triage
This skill helps you triage PR status and CI failures in Next.js projects by prioritizing blockers and reproducing locally.
npx playbooks add skill vercel/next.js --skill pr-status-triageReview the files below or copy the command above to add this skill to your agents.
---
name: pr-status-triage
description: >
Triage CI failures and PR review comments using scripts/pr-status.js.
Use when investigating failing CI jobs, flaky tests, or PR review feedback.
Covers blocker-first prioritization (build > lint > types > tests),
CI env var matching for local reproduction, and the Known Flaky Tests
distinction.
---
# PR Status Triage
Use this skill when the user asks about PR status, CI failures, or review comments in the Next.js monorepo.
## Workflow
1. Run `node scripts/pr-status.js` (or `node scripts/pr-status.js <number>`).
2. Read generated files in `scripts/pr-status/`.
3. Prioritize blocking jobs first: build, lint, types, then test jobs.
4. Treat failures as real until disproven; check the "Known Flaky Tests" section before calling anything flaky.
5. Reproduce locally with the same mode and env vars as CI.
## Quick Commands
```bash
node scripts/pr-status.js
node scripts/pr-status.js <number>
```
## Detailed References
- [workflow.md](./workflow.md) - prioritization and common failure patterns
- [local-repro.md](./local-repro.md) - mode/env matching and isolation guidance
This skill automates triage of pull request status, CI failures, and review comments using the scripts/pr-status.js helper. It speeds investigation by generating a prioritized view of failing jobs, environment details for local reproduction, and a list of known flaky tests. Use it to decide what to fix first and how to reproduce issues reliably.
Run the script to produce a report directory containing job statuses, failure excerpts, and CI environment variables for the PR. The output highlights blocking jobs and annotates failures with flaky-test information when available. It also surfaces the CI mode and env var settings so you can replicate the failing run locally.
How do I run the triage script for a specific PR?
Run node scripts/pr-status.js <number> to generate a report for that PR in the output directory.
What order should I fix failures in?
Fix blocking categories first: build, then lint, then types, and finally test jobs.
When can I mark a failing test as flaky?
Only after checking the Known Flaky Tests list and reproducing the failure locally with the same CI mode and env vars.