Public: anyone can read this; the crew can change it.
Crash reports: a private app's owner makes a report key, and a build with it can file reports without a session #18238
Closed 2h 37m ago
A private app's owner can now make a report key, and a build that sends it files crash reports without a session. I ran bun x tsc --noEmit and the focused tests (test/report-key.test.ts, test/crash-reports.test.ts, test/schema-migrations.test.ts, the contract and docs suites).
-
Reviews
No review yet.
-
Checks
stopped closed without shipping deploy 5479989
-
History
- Report key: regenerate the route index 5479989
- Report key: settings block is behind the owner's sign-in c31db12
- Report key: its how-to e422a23
- Report key: pin its migration, route roles, wrap comments a2a6262
- Crash reports: a private app's owner makes a report key; a build with it files reports without a session 3fbfa37
- Crash reports: the route accepts the Apple app's body (os, device, at, previousRun, findings) (#18226) 24247ac
- Games: spark profile call tree and flame graph on the forge (#18211) 5ce50ab
- Stop and Delete a cloud machine or volume from the cost row, each confirmed only by typing its name (#18187) bcce730
- Access 5c: a linked game player mints the visitor principal (#18209) d46f453
- A changes-requested review with only a body is invisible: the pull's API, its reviews list and a repeat review request all say nothing (#18184) 1b94cba
- Full suite red: 3 files in check run 01m90cxa10vb1wxr16pmrhnt09 (#18225) 831c98f
- Game door: plain questions go to Talk at once, and continue until /forge clear (#18055) b5161cb
- Spend 3: the same cost reads and planned stop/delete as MCP tools and a terminal screen (#18206) c30e6bb
- Games: host the spark profiler viewer and its uploads in the forge (#18096) beabbda
- Games: a day after a mod set is installed, the games page says whether it helped, with take-back one tap away (#18201) 2243020
- Games: installing the quality set ships Essential Commands' config with only /home, /spawn and /tpa on (#18199) 7b84b2c
- Connections on an account: verified identities the person controls, each with its own uses, and a lookup that answers only on opt-in (#18120) 314f4eb
- A granted app's two-page print comes out as one sheet, printed on both sides (#18194) e2e7eb4
- Traces 5c: the trace list and one trace read through MCP tools and a terminal screen compare (#18183) cc38920
- Access 5a: a visitor principal is minted only when a visitor creates something, signed, with a role in may() and per-visitor limits (#18174) e261ee9
2 earlier comments · 1 event
A private app's owner can now make a report key, and a build that sends it files crash reports without a session. I ran bun x tsc --noEmit and the focused tests (test/report-key.test.ts, test/crash-reports.test.ts, test/schema-migrations.test.ts, the contract and docs suites). I did not run a bare bun test, and I have not tried it on a preview. The gate is clean on the last run; design-lint was last run before the how-to and the "No look" commit.
- Key: the owner makes it from the app's settings (a "Report key" block, shown only on private apps), from the terminal palette ("Report key":
mmakes or rotates,xrevokes), or throughPOSTandDELETE /api/v1/apps/:owner/:name/report-key(rw token). The three share their words insrc/actions/report_keys.ts. The key is shown once, only its sha256 is kept, and making another replaces the old one. - Accepting reports:
POST …/crash-reportstakes a private app's report when it carries the key in anx-report-keyheader. Otherwise the existing rules apply, so a wrong, revoked or missing key gets the identical 404 body as an app that does not exist. The key opens that one route, and the same 5 a minute per address and 60 a minute per app still apply. - Test:
test/report-key.test.tsmakes a key, files a report with it, shows a wrong key and a missing key get the missing-app 404 body, and shows the key can't reach the key route or the repo page. It then rotates the key (the old one stops), revokes it, and files again to get the same 404. - Docs and migration:
docs/features/report-key.mdand a paragraph incrash-reports.md; the migration20261204120000-report-keyis pinned. - Reused: the secret and hash helpers (
secret(),sha256),adminFormandflashTo(the one-shot flash that shows the key once) for the page, and the secrets settings block as the template for the page and terminal screens.bun scripts/gate.ts --fixlisted near-duplicate functions but I did not merge any. - One table instead of a token row: the issue said to use the token pattern, but a
tokenrow authenticates as its user across the whole API, so the key would not be limited to this one route. I copied the pattern (rk_prefix, shown once, hash only) into a smallreport_keytable with one row per app andON DELETE CASCADE. - Left out: more than one key per app, last-used tracking, and a key for public apps (making one answers 422
off).
[
{"go":"/<owner>/<private-app>/settings/app#report-key","look":"Report key block; press Make a key","expect":"a one-shot flash shows rk_… once; the block then says Made <time> and offers Rotate and Revoke"},
{"go":"POST /api/v1/apps/<owner>/<private-app>/crash-reports with header x-report-key","look":"the key from the flash","expect":"202; after Revoke, or with a wrong key, the same 404 as an app that does not exist"}
]The check failed because the generated route index was stale. It was missing the export for deleteApiV1AppsOwnerNameReportKey. I regenerated it with bun scripts/openapi-routes.ts and pushed the result as one commit.
- Tests:
test/openapi-routes.test.tspasses locally (589 tests). I did not run the other tests, so the forge's full check on this push is the rest of the verification. - Type check:
bun x tsc --noEmitprinted no errors. - Gate:
bun scripts/gate.ts --fixchanged nothing. It still prints a similarity note thatreportKeyMakeandreportKeyRevokeinsrc/web/pages/report_key.tslook alike (0.73). That is advisory, so I left it. - Door rule: the commit message says
No door:because only the generated index changed, with no behaviour change.
A private app's owner can now make a report key, and a build that sends it files crash reports without a session. I ran
bun x tsc --noEmitand the focused tests (test/report-key.test.ts,test/crash-reports.test.ts,test/schema-migrations.test.ts, the contract and docs suites). I did not run a barebun test, and I have not tried it on a preview. The gate is clean on the last run;design-lintwas last run before the how-to and the "No look" commit.mmakes or rotates,xrevokes), or throughPOSTandDELETE /api/v1/apps/:owner/:name/report-key(rw token). The three share their words insrc/actions/report_keys.ts. The key is shown once, only its sha256 is kept, and making another replaces the old one.POST …/crash-reportstakes a private app's report when it carries the key in anx-report-keyheader. Otherwise the existing rules apply, so a wrong, revoked or missing key gets the identical 404 body as an app that does not exist. The key opens that one route, and the same 5 a minute per address and 60 a minute per app still apply.test/report-key.test.tsmakes a key, files a report with it, shows a wrong key and a missing key get the missing-app 404 body, and shows the key can't reach the key route or the repo page. It then rotates the key (the old one stops), revokes it, and files again to get the same 404.docs/features/report-key.mdand a paragraph incrash-reports.md; the migration20261204120000-report-keyis pinned.secret(),sha256),adminFormandflashTo(the one-shot flash that shows the key once) for the page, and the secrets settings block as the template for the page and terminal screens.bun scripts/gate.ts --fixlisted near-duplicate functions but I did not merge any.tokenrow authenticates as its user across the whole API, so the key would not be limited to this one route. I copied the pattern (rk_prefix, shown once, hash only) into a smallreport_keytable with one row per app andON DELETE CASCADE.off).Closes #18224