feat: demo Guests and devtools on local and preview stacks #522
No reviewers
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
spec
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
amaurycoudr/chess-project!522
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "spec/394-demo-guests"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Local and preview stacks carry two Demo Guests with decided Games, and the TanStack devtools gain a Guest panel to switch to one. One image everywhere: the gate is the runtime flag
DEVTOOLS_ENABLED, on only when exactlytrue(ADR 0039).DEMO_OPPONENT, holds the other Seat in A's Games. It is not a Demo Guest offered by the probe; it exists because B may own only one Game.GLOSSARY.mdand ADR 0039 to the index.apps/api/.oxlintrc.jsongains adevtoolslayer aftergames.Proposed rule changes
CODING_STANDARDS.mdrule 1, and the layer rule's message inapps/api/.oxlintrc.json, still list onlyroom/,games/,common/andconfig/; they should namedevtools/.Evidence
After: gate green (api 513, front 1104, engine 738 tests);
apps/e2e36/36 in itsbuilttarget with devtools on.demoGuestsmount no devtools and keep the board; a 200 probe mounts the Guest panel; "Switch to…" and "Paste a secret" change the next request'sx-guestand My games refetches; an empty paste is refused.language-switch.test: an unstubbed probe got Vite'sindex.htmlas a 200, and the panel crashed the root. The probe answer is now checked againstDevtoolsProbeSchema.up.shandverify.shagainst a preview and production; the Guest panel inside the real TanStack devtools shell.Merge Danger
Door: two-way
The seed only upserts fixed ids and refuses without the flag; no migration.
Blast Radius: deploys
up.shandverify.shnow fail a preview whose seed fails, and fail production if/rpc/devtoolsanswers anything but 404. Existing worktrees needpnpm env:sync(run bypnpm install) beforepnpm dev, or the seed step refuses.Closes #394
Closes #395
Closes #396
Closes #397
Screenshots
Before is production, after is this merge request's review app at
960aace.Desktop
Mobile
added 4 commits
d66cfef5- feat(contracts): add the devtools probe, GET /devtools, answering the Demo Guestsac98523c- feat(api): answer the devtools probe with the Demo Guests, only with devtools on43204a29- feat(ci): turn devtools on in every preview's app, and verify the probe by stack6ff5425a- feat(front): mount the devtools only after a 200 devtools probe, from a lazy chunkCompare with previous version
added 1 commit
e968f642- feat(front): switch the browser's Guest from a Guest panel in the devtoolsCompare with previous version
added 10 commits
Compare with previous version
marked this merge request as ready
changed the description
added 23 commits
d59ded02- 1 commit from branchmainca6d6960- chore(api): give devtools a layer of their own after games in the API lint confige335454e- refactor(api): move the devtools module and controller to a devtools/ feature folder98f907eb- refactor(api): map a decided Game to its games row in one functionde23bdb1- test(front): build the devtools test's Games from the games harness' stored Gamee19edd09- fix(front): mount the devtools only for a probe answer that lists Demo Guests3d1e3e5b- test(api): play a Room's line as the string the Game stores, under one Fool's Mate name75f423a3- docs(repo): drop two ADR 0039 citations for claims the ADR does not make5109e874- refactor(api): hand the demo seed the devtools flag its entry point parsed63faee27- refactor(front): spare the probe's key from a Guest switch through the probe's own query options960aace0- refactor(ci): ask is_preview whether a stack is a preview, in every deploy scriptCompare with previous version