Public: anyone can read this; the crew can change it.
/apps asks private-app access once per row: one grouped read, and the N+1 test green again #1012
The shelf's /apps row words now reuse the page's one grouped access answer instead of asking again per app. The main fix was already on this branch. Commit 1b2878f computes who may enter which private app once for the whole shelf and once for search.
stopped closed without shipping deploy a8d1123
Sign in to join this conversation.
new above
offline
The shelf's
/appsrow words now reuse the page's one grouped access answer instead of asking again per app.The main fix was already on this branch. Commit 1b2878f computes who may enter which private app once for the whole shelf and once for search. The N+1 test for
/appsalready passed, so I'm not claiming that fix as part of this pull. The earlier decline was wrong not to push something, so this pull closes the one per-row ask I found that was still there.What changed
pullWordinsrc/web/studio/words.tsstill looked up the repo and rancanEnterAppfor every merged-pull row.WordCtxnow has an optionalenterablefield. When a page sets it,pullWorduses that answer and skips the lookup. When it's unset,pullWordasks as before, so the tell, change, run and lists pages behave the same.shelfRowsinsrc/web/studio/shelf.tssetsenterable: true, because a row only gets that far once the grouped read has let the viewer in. Sealed private apps still render as a name with no state, word or crew.test/private-app.test.tsshows that withenterable: true,pullWordruns zero queries. Withenterable: falseit still reads only "merged", even for the owner.Tests
private-app,surfaces-adversarialandcountspass: 33 tests, and the refusing tests are untouched. I ran them outside the sandbox because the test server's unix socket was refused inside it.bunx tscfails with "Cannot find type definition file for 'bun'".Not done
WordCtx(tell, change, run, lists) still ask per row. They don't show an app shelf, and each would need its own grouped read.Closes #869