Commit 28e279a
fix(build): tolerate trailing commas when reading wrangler.jsonc
After the D1 migration succeeds, migrate-production.mjs calls
wranglerD1DatabaseIds() -> readWranglerConfig(), which did
JSON.parse(stripJsonComments(text)). strip-json-comments removes comments but
not trailing commas, so wrangler.jsonc (e.g. `"binding": "ASSETS",` before `}`)
threw 'Expected double-quoted property name in JSON'. Strip trailing commas too.
Surfaced now that the Cloudflare build gets past migrate (Node 24 pin + D1
adapter wiring): the D1 schema migration runs and succeeds, then this parse ran.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent d09e34d commit 28e279a
1 file changed
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
3 | 6 | | |
4 | 7 | | |
5 | 8 | | |
| |||
10 | 13 | | |
11 | 14 | | |
12 | 15 | | |
13 | | - | |
| 16 | + | |
| 17 | + | |
14 | 18 | | |
15 | 19 | | |
16 | 20 | | |
| |||
0 commit comments