fix(battle-viewer): unblock synthetic-game battle load #16
Reference in New Issue
Block a user
Delete Branch "feature/synthetic-battle-loading-fix"
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
lib/active-view/battle.sveltewas waiting on aGalaxyClienthandle that the in-game shell layout deliberately never publishes for synthetic-report games, so clicking a battle cross in any synthetic game (e.g. loaded fromtools/local-dev/reports/dg/KNNTS041.json) sat on "loading battle…" forever.isSyntheticGameId(gameId)—fetchBattlealready resolves synthetic ids from the in-memory fixture map and ignores the client. Widen its signature toGalaxyClient | null.docs/FUNCTIONAL.md§6.5 + Russian mirror in sync with the Phase 28 ConnectRPC migration (still described the pre-Phase-28 raw REST path).Test plan
npx vitest run game-shell-stubs.test.ts— 9 tests pass, including two new regressions (synthetic + missing fixture → not_found; synthetic + registered fixture → BattleViewer mounts)npx vitest run— full suite 651/651 greennpm run check— svelte-check 0 errors / 0 warningshttps://www.galaxy.lan, open a synthetic-report game from KNNTS041.json, click a battle cross — viewer renders instead of hanging