[PR #1454] [MERGED] Fix Game QA console errors #5095

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

📋 Pull Request Information

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

Base: refactor ← Head: fix/game-qa-console-errors


📝 Commits (1)

  • 58d60b6 Fix Game QA console errors

📊 Changes

2 files changed (+27 additions, -17 deletions)

View changed files

📝 src/features/modes/game/components/GameSurface.tsx (+9 -3)
📝 src/features/modes/shared/chat-ui/components/ChatSettingsDrawer.tsx (+18 -14)

📄 Description

Linked issue

Closes #1452
Closes #1453

Why this change

  • The post-#1449 Game QA sweep found two confirmed console failures: provider/runtime recovery rows emitted uncaught pageerror events, and opening the Game settings drawer emitted React's nested <button> validation error from Advanced Parameters.

What changed

  • Catch fire-and-forget generateGameTurn(...) rejections in Game setup/retry/send callbacks after the generation UI has already rendered the recoverable toast/error state.
  • Split the Advanced Parameters drawer header so the collapsible header button no longer contains HelpTooltip's own button.

Refactor impact

Primary owner:

Game mode / shared mode UI

Impact areas reviewed:

  • Game turn generation UI boundary
  • Game settings drawer
  • Shared chat settings Advanced Parameters section

Boundary notes:

  • No engine, storage schema, provider protocol, prompt assembly, remote runtime, or Rust changes.
  • The Game generation contract is unchanged; this only handles rejected UI promises that were already surfaced to the user by runGenerationWithUi.

Pressure points touched:

  • GameSurface
  • ChatSettingsDrawer

Validation

  • pnpm check passes locally
  • pnpm typecheck passes locally
  • pnpm build passes locally
  • pnpm check:architecture passes locally
  • pnpm check:docs passes locally
  • cargo check --manifest-path src-tauri/Cargo.toml --workspace passes locally
  • Rust clippy/tests were run for Rust behavior changes
  • Browser or Tauri app manual verification completed
  • Playwright, screenshot, or recording evidence added for UI changes
  • Remote runtime smoke checked when relevant

Manual verification notes

  • Codex ran the focused Game QA subset against the web shell + remote runtime:
    • MARINARA_QA_OUT_DIR=scratch/game-qa-console-fix-focused MARINARA_QA_ONLY_BLOCKS=core-flow,game-systems,failure-recovery node scratch\game-qa-runner.mjs
    • The rerun passed the provider 500, provider 429, malformed provider, timeout, runtime offline mid-turn, deleted active game id, and stale active game id recovery rows.
    • scratch/game-qa-console-fix-focused/console.json contained no pageerror entries and no non-intentional React/error console entries after the fix.
  • Codex ran pnpm check, which passed.
  • Codex ran node C:\Users\celia\.codex\tools\marinara-proof-gate.mjs scratch/bugfix-verification.json, which passed.
  • graphify update . was attempted but timed out after about 10 minutes in this shell; no Graphify output is included in this PR.

Docs and release impact

  • No docs changes needed
  • Updated README.md
  • Updated CONTRIBUTING.md
  • Updated docs/developer/
  • Updated repo skills or AGENTS.md
  • Confirmed this PR does not restore old staging/package-workspace/release claims

UI evidence

No GitHub-renderable screenshots are attached. The proof for this bug is the before/after console audit:

  • Before: scratch/game-qa-post-1449-full-clean/console.json
  • After: scratch/game-qa-console-fix-focused/console.json

Summary by CodeRabbit

  • Refactor
    • Improved error handling in game turn generation workflows to prevent unhandled promise rejections while maintaining existing error states.
    • Enhanced Advanced Parameters section with proper button semantics and improved tooltip accessibility.

Review Change Stack


🔄 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/1454 **Author:** [@cha1latte](https://github.com/cha1latte) **Created:** 5/28/2026 **Status:** ✅ Merged **Merged:** 5/28/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `refactor` ← **Head:** `fix/game-qa-console-errors` --- ### 📝 Commits (1) - [`58d60b6`](https://github.com/Pasta-Devs/Marinara-Engine/commit/58d60b6b27e6ee13c7aa24694b8159939180f251) Fix Game QA console errors ### 📊 Changes **2 files changed** (+27 additions, -17 deletions) <details> <summary>View changed files</summary> 📝 `src/features/modes/game/components/GameSurface.tsx` (+9 -3) 📝 `src/features/modes/shared/chat-ui/components/ChatSettingsDrawer.tsx` (+18 -14) </details> ### 📄 Description <!-- Target branch: `refactor`. Change the base to `refactor` before submitting unless a maintainer explicitly asked for another base. --> <!-- Keep all checkboxes unchecked until a human has actually verified them. --> ## Linked issue Closes #1452 Closes #1453 ## Why this change - The post-#1449 Game QA sweep found two confirmed console failures: provider/runtime recovery rows emitted uncaught `pageerror` events, and opening the Game settings drawer emitted React's nested `<button>` validation error from Advanced Parameters. ## What changed - Catch fire-and-forget `generateGameTurn(...)` rejections in Game setup/retry/send callbacks after the generation UI has already rendered the recoverable toast/error state. - Split the Advanced Parameters drawer header so the collapsible header button no longer contains `HelpTooltip`'s own button. ## Refactor impact Primary owner: Game mode / shared mode UI Impact areas reviewed: - Game turn generation UI boundary - Game settings drawer - Shared chat settings Advanced Parameters section Boundary notes: - No engine, storage schema, provider protocol, prompt assembly, remote runtime, or Rust changes. - The Game generation contract is unchanged; this only handles rejected UI promises that were already surfaced to the user by `runGenerationWithUi`. Pressure points touched: - `GameSurface` - `ChatSettingsDrawer` ## Validation - [ ] `pnpm check` passes locally - [ ] `pnpm typecheck` passes locally - [ ] `pnpm build` passes locally - [ ] `pnpm check:architecture` passes locally - [ ] `pnpm check:docs` passes locally - [ ] `cargo check --manifest-path src-tauri/Cargo.toml --workspace` passes locally - [ ] Rust clippy/tests were run for Rust behavior changes - [ ] Browser or Tauri app manual verification completed - [ ] Playwright, screenshot, or recording evidence added for UI changes - [ ] Remote runtime smoke checked when relevant ### Manual verification notes - Codex ran the focused Game QA subset against the web shell + remote runtime: - `MARINARA_QA_OUT_DIR=scratch/game-qa-console-fix-focused MARINARA_QA_ONLY_BLOCKS=core-flow,game-systems,failure-recovery node scratch\game-qa-runner.mjs` - The rerun passed the provider 500, provider 429, malformed provider, timeout, runtime offline mid-turn, deleted active game id, and stale active game id recovery rows. - `scratch/game-qa-console-fix-focused/console.json` contained no `pageerror` entries and no non-intentional React/error console entries after the fix. - Codex ran `pnpm check`, which passed. - Codex ran `node C:\Users\celia\.codex\tools\marinara-proof-gate.mjs scratch/bugfix-verification.json`, which passed. - `graphify update .` was attempted but timed out after about 10 minutes in this shell; no Graphify output is included in this PR. ## Docs and release impact - [ ] No docs changes needed - [ ] Updated `README.md` - [ ] Updated `CONTRIBUTING.md` - [ ] Updated `docs/developer/` - [ ] Updated repo skills or `AGENTS.md` - [ ] Confirmed this PR does not restore old staging/package-workspace/release claims ## UI evidence No GitHub-renderable screenshots are attached. The proof for this bug is the before/after console audit: - Before: `scratch/game-qa-post-1449-full-clean/console.json` - After: `scratch/game-qa-console-fix-focused/console.json` <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Improved error handling in game turn generation workflows to prevent unhandled promise rejections while maintaining existing error states. * Enhanced Advanced Parameters section with proper button semantics and improved tooltip accessibility. <!-- review_stack_entry_start --> [![Review Change Stack](https://storage.googleapis.com/coderabbit_public_assets/review-stack-in-coderabbit-ui.svg)](https://app.coderabbit.ai/change-stack/Pasta-Devs/Marinara-Engine/pull/1454?utm_source=github_walkthrough&utm_medium=github&utm_campaign=change_stack) <!-- review_stack_entry_end --> <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-22 04:13:11 +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#5095
No description provided.