extremely claude-assisted go game based on atproto! working on cleaning up and giving a more unique design, still has a bit of a slop vibe to it.
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix game status: use DB index as authority for status and playerTwo

The join endpoint can't write to player one's PDS repo (ATProto constraint),
so the PDS game record never gets updated with playerTwo or status='active'.
The DB index is the source of truth for these fields since the join endpoint
controls them. PDS remains authoritative for scores and winner.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

+6 -4
+6 -4
src/routes/game/[id]/+page.svelte
··· 34 34 let playerOneHandle = $state<string>(data.creatorDid); 35 35 let playerTwoHandle = $state<string | null>(data.playerTwoDid); 36 36 37 - // Derived game state — use PDS record when available, fall back to DB index 38 - const gameStatus = $derived(gameRecord?.status ?? data.status); 37 + // DB index is authoritative for status and playerTwo (set by join endpoint, 38 + // which can't write to player one's PDS repo). PDS is authoritative for 39 + // scores and winner (written by game creator). 40 + const gameStatus = $derived(data.status); 39 41 const gameBoardSize = $derived(gameRecord?.boardSize ?? data.boardSize); 40 - const gamePlayerOne = $derived(gameRecord?.playerOne ?? data.creatorDid); 41 - const gamePlayerTwo = $derived(gameRecord?.playerTwo ?? data.playerTwoDid); 42 + const gamePlayerOne = $derived(data.creatorDid); 43 + const gamePlayerTwo = $derived(data.playerTwoDid); 42 44 const gameWinner = $derived(gameRecord?.winner ?? null); 43 45 const gameBlackScore = $derived(gameRecord?.blackScore ?? null); 44 46 const gameWhiteScore = $derived(gameRecord?.whiteScore ?? null);