[PR #663] [MERGED] Fix GM chapter start after recap #4717

Closed
opened 2026-10-22 04:10:05 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/663
Author: @cha1latte
Created: 5/11/2026
Status: ✅ Merged
Merged: 5/11/2026
Merged by: @cha1latte

Base: main ← Head: fix/issue-654-gm-chapter-start


📝 Commits (1)

  • dd9b493 Fix GM chapter start after recap

📊 Changes

4 files changed (+16 additions, -12 deletions)

View changed files

➕ docs/pr-evidence/issue-654/README.md (+3 -0)
➕ docs/pr-evidence/issue-654/after.png (+0 -0)
➕ docs/pr-evidence/issue-654/before.png (+0 -0)
📝 packages/client/src/components/game/GameSurface.tsx (+13 -12)

📄 Description

Linked issue

Closes #654

Why this change

  • Generated GM follow-up sessions can include a narrator recap before the player presses Start Game. The start screen treated that recap as if the first playable GM turn already existed, which could leave the chapter stuck or hide the recovery path when startup generation did not produce an assistant message.

What changed

  • Changed the game start screen's first-turn gate to count only assistant GM messages as playable game content.
  • Kept the Retry recovery visible when a ready/active generated session has only narrator recap content and no assistant GM turn.
  • Added scoped PR evidence screenshots for issue #654.

Validation

  • pnpm check passes locally
  • Container (Docker / Podman) built and ran without issue
  • Ran the app, clicked through the changes manually
  • Checked edge cases (light + dark mode, mobile viewport, empty states, error paths)
  • Above manual verification completed (describe below)
  • Read and followed CONTRIBUTING.md

Manual verification notes

  • Codex proof: node scratch/issue-654-first-turn-gate.mjs passed. It verifies that a narrator-only generated session recap no longer unlocks the first-turn gate, a real assistant GM turn still unlocks it, and an empty hidden assistant anchor does not unlock it.
  • Codex browser proof: seeded a local GM Session 3 with gameSessionStatus: "ready" and a narrator recap but no assistant GM message, opened it in the app, clicked Start Game, and confirmed the screen remains recoverable with Retry visible after generation failed due to no configured API connection.
  • Codex baseline: pnpm check passed.
  • Codex evidence artifact: scratch/bugfix-verification.json records the repro, visual proof, baseline, and final done gate.

Docs and release impact

  • No docs changes needed
  • Updated docs (README / CONTRIBUTING / android/README / CHANGELOG) as needed
  • Version/release files updated (only if this PR includes a version bump)

No docs, schema, dependency, version, or release-file changes are needed for this focused UI-state fix.

UI evidence (if applicable)

Before: ready generated session with only a narrator recap still shows Start Game.

Before

After: after Start Game fails to produce an assistant GM turn in the proof environment, the same screen stays recoverable and shows Retry instead of treating the recap as playable content.

After


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Engine/pull/663 **Author:** [@cha1latte](https://github.com/cha1latte) **Created:** 5/11/2026 **Status:** ✅ Merged **Merged:** 5/11/2026 **Merged by:** [@cha1latte](https://github.com/cha1latte) **Base:** `main` ← **Head:** `fix/issue-654-gm-chapter-start` --- ### 📝 Commits (1) - [`dd9b493`](https://github.com/Pasta-Devs/Marinara-Engine/commit/dd9b4939fab6677006acc42903140384d1113db1) Fix GM chapter start after recap ### 📊 Changes **4 files changed** (+16 additions, -12 deletions) <details> <summary>View changed files</summary> ➕ `docs/pr-evidence/issue-654/README.md` (+3 -0) ➕ `docs/pr-evidence/issue-654/after.png` (+0 -0) ➕ `docs/pr-evidence/issue-654/before.png` (+0 -0) 📝 `packages/client/src/components/game/GameSurface.tsx` (+13 -12) </details> ### 📄 Description ## Linked issue <!-- Every PR should reference a feature request or issue report. If there isn't one yet, open one first to gather opinions: --> <!-- https://github.com/Pasta-Devs/Marinara-Engine/issues/new/choose --> Closes #654 ## Why this change <!-- What user problem, bug, or goal does this solve? --> - Generated GM follow-up sessions can include a narrator recap before the player presses **Start Game**. The start screen treated that recap as if the first playable GM turn already existed, which could leave the chapter stuck or hide the recovery path when startup generation did not produce an assistant message. ## What changed <!-- List the key changes in this PR --> - Changed the game start screen's first-turn gate to count only assistant GM messages as playable game content. - Kept the **Retry** recovery visible when a ready/active generated session has only narrator recap content and no assistant GM turn. - Added scoped PR evidence screenshots for issue #654. ## Validation <!-- Required: include commands run and/or manual checks performed --> - [ ] `pnpm check` passes locally - [ ] Container (Docker / Podman) built and ran without issue - [ ] Ran the app, clicked through the changes manually - [ ] Checked edge cases (light + dark mode, mobile viewport, empty states, error paths) - [ ] Above manual verification completed (describe below) - [ ] Read and followed `CONTRIBUTING.md` ### Manual verification notes <!-- Describe exactly what you tested in a real browser/app, step by step. --> <!-- ⚠️ If an AI agent filled out or ticked these boxes for you, treat them --> <!-- as a TO-DO LIST, not as proof the work is done. Verify each item yourself --> <!-- before submitting. If you haven't verified it, untick the box. --> - Codex proof: `node scratch/issue-654-first-turn-gate.mjs` passed. It verifies that a narrator-only generated session recap no longer unlocks the first-turn gate, a real assistant GM turn still unlocks it, and an empty hidden assistant anchor does not unlock it. - Codex browser proof: seeded a local GM Session 3 with `gameSessionStatus: "ready"` and a narrator recap but no assistant GM message, opened it in the app, clicked **Start Game**, and confirmed the screen remains recoverable with **Retry** visible after generation failed due to no configured API connection. - Codex baseline: `pnpm check` passed. - Codex evidence artifact: `scratch/bugfix-verification.json` records the repro, visual proof, baseline, and final done gate. ## Docs and release impact - [ ] No docs changes needed - [ ] Updated docs (README / CONTRIBUTING / android/README / CHANGELOG) as needed - [ ] Version/release files updated (only if this PR includes a version bump) No docs, schema, dependency, version, or release-file changes are needed for this focused UI-state fix. ## UI evidence (if applicable) <!-- Add before/after screenshots or recordings for UI changes --> Before: ready generated session with only a narrator recap still shows **Start Game**. ![Before](https://raw.githubusercontent.com/cha1latte/Marinara-Engine/dd9b4939fab6677006acc42903140384d1113db1/docs/pr-evidence/issue-654/before.png) After: after **Start Game** fails to produce an assistant GM turn in the proof environment, the same screen stays recoverable and shows **Retry** instead of treating the recap as playable content. ![After](https://raw.githubusercontent.com/cha1latte/Marinara-Engine/dd9b4939fab6677006acc42903140384d1113db1/docs/pr-evidence/issue-654/after.png) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-22 04:10:05 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#4717
No description provided.