withastro/astro

8 rules learned from 1,000 merged PRs: the files and habits in withastro/astro that kept needing a fix after merge.

Merged PRs read
1,000
Needed a fix
33 (3.6%)
Reverted
4
Merged between
2026-05-11 and 2026-11-10

Tested on new PRs: not enough data yet

2 of the 18 code PRs that breached a rule needed a fix (11%), against 4 of the 136 that breached none (3%).

Rules were learned from older PRs, then tested on later PRs they hadn't seen. How we tested

Fix-prone files and folders

PRs that touched these paths needed a follow-up fix more often than the 4% repo average. Counts are PRs that touched the path.

  1. Hotspot: packages/astro/src/core/dev/lockfile.ts

    2 of 9 earlier PRs that changed this needed a fix.

    7 clean, 2 fixed (22%)
  2. Hotspot: packages/markdown/satteri/src/satteri-processor.ts

    2 of 10 earlier PRs that changed this needed a fix.

    8 clean, 2 fixed (20%)
  3. Fragile area: packages/create-astro/

    2 of 11 earlier PRs that changed this needed a fix.

    9 clean, 2 fixed (18%)
  4. Hotspot: packages/astro/src/types/public/config.ts

    5 of 28 earlier PRs that changed this needed a fix.

    23 clean, 5 fixed (18%)
  5. Hotspot: packages/astro/src/core/fetch/fetch-state.ts

    6 of 34 earlier PRs that changed this needed a fix.

    28 clean, 6 fixed (18%)
  6. Hotspot: packages/integrations/cloudflare/src/index.ts

    5 of 39 earlier PRs that changed this needed a fix.

    34 clean, 5 fixed (13%)
  7. Fragile area: packages/upgrade/

    1 of 9 earlier PRs that changed this needed a fix.

    8 clean, 1 fixed (11%)
  8. Hotspot: pnpm-workspace.yaml

    3 of 33 earlier PRs that changed this needed a fix.

    30 clean, 3 fixed (9%)

Conventions

Habits most PRs here follow, where PRs that broke them needed a fix more often. Counts on each bar are the PRs that broke it.

No habit here made the list.

Recent PRs that needed a fix

Rules flagged 58 recent PRs, and 6 of those needed a fix (10%), against 2% of all recent PRs. These are the 5 that needed a fix, with the PR that fixed each.

PRTitleSizeRule it breachedWhat happened
fix(satteri): reset heading slugs between renders +47 -22 touches packages/markdown/satteri/src/satteri-processor.ts8 clean, 2 fixed fixed in #18047, same day
Increase minimum Node.js version to 22.22.0 +65 -41 touches packages/create-astro/9 clean, 2 fixed fixed in #18475, 7 days later
refactor(assets): remove globalThis.astroAsset image tracking +2,125 -1,342 touches packages/astro/src/types/public/config.ts23 clean, 5 fixed fixed in #18383, 1 day later
Support Cloudflare Vite plugin v2 +1,075 -1,452 touches packages/integrations/cloudflare/src/index.ts34 clean, 5 fixed fixed in #18196, 8 days later
Compile images by default with Cloudflare adapter +278 -33 touches packages/integrations/cloudflare/src/index.ts34 clean, 5 fixed fixed in #18032, 6 days later

Get this for your own repo

Precall reads your repo's history the same way and comments on new PRs that touch the spots that kept breaking. Download the rules file for withastro/astro.