[PR #5896] [MERGED] fix(client): record reload and render recovery diagnostics #6988

Closed
opened 2026-10-23 04:15:30 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/5896
Author: @SpicyMarinara
Created: 9/6/2026
Status: ✅ Merged
Merged: 9/6/2026
Merged by: @SpicyMarinara

Base: staging ← Head: fix/5870-client-recovery-diagnostics


📝 Commits (4)

  • 80b81d5 docs: scope client recovery diagnostics for #5870
  • e5186c5 feat(client): retain bounded private-safe recovery observations
  • 4cd59e4 docs(client): clarify manual export of recovery diagnostics
  • 89cadad Merge remote-tracking branch 'origin/staging' into fix/5870-client-recovery-diagnostics

📊 Changes

15 files changed (+677 additions, -10 deletions)

View changed files

📝 CHANGELOG.md (+1 -0)
➕ e2e/client-runtime-diagnostics.e2e.ts (+181 -0)
📝 packages/client/src/App.tsx (+6 -3)
📝 packages/client/src/components/capabilities/CapabilityElement.tsx (+2 -1)
📝 packages/client/src/components/chat/ChatMessage.tsx (+2 -0)
📝 packages/client/src/components/panels/SettingsPanel.tsx (+2 -0)
📝 packages/client/src/hooks/use-generate.ts (+3 -0)
📝 packages/client/src/lib/app-update-prompt.ts (+2 -1)
📝 packages/client/src/lib/browser-runtime.ts (+12 -2)
➕ packages/client/src/lib/client-runtime-diagnostics.ts (+238 -0)
📝 packages/client/src/lib/support-diagnostics.ts (+6 -0)
📝 packages/client/src/localization/locales/en.json (+1 -1)
📝 packages/client/src/main.tsx (+8 -1)
➕ scripts/regressions/client-runtime-diagnostics.regression.ts (+212 -0)
📝 scripts/regressions/tsconfig.client-lanes.json (+1 -1)

📄 Description

Linked issue

Related to #5870. Keep that issue open: this diagnostic follow-up does not resolve or reproduce the physical-iPhone failure.

Why this change

The maintainer still sees full-page refreshes and intermittent black screens in the installed iPhone app, including after editing and scrolling without image generation. Existing Support Diagnostics reports server health but cannot distinguish an app-requested client reload from an unknown browser interruption. The approved follow-up adds that missing evidence without another speculative rendering workaround.

What changed

  • Include the actual frontend build, viewport/root geometry and the last 16 local client events in Copy Support Diagnostics.
  • Mark existing reload paths, observed JavaScript/React errors, and generic edit/image-arrival milestones. No new automatic reload, polling, scroll listener or network telemetry.
  • Reconstruct stored records through a strict allowlist; exclude chat text, prompts, image URLs and raw exception messages/stacks. Deduplicate errors and tolerate unavailable/malformed storage.
  • Preserve appearance settings, original image quality, existing preview bounds and generation recovery behavior. No new dependency or version bump.
  • Update the canonical English diagnostics description and Unreleased changelog.

Validation

Automated evidence: implementation e5186c54a, privacy wording clarification 4cd59e411, final integrated head 89cadad2cf7bace2373e46704af3f6c3f7f64640 (staging update #5894; no additional client behavior change):

  • pnpm install and pnpm check passed (including localization, TypeScript, lint and production build); pnpm check passed again at the final integrated head.
  • Focused Node regression passed: cross-page persistence, privacy, malformed/oversized records, blocked/quota storage, error storms, reload attribution and the existing recovery cooldown.
  • 24 focused browser checks passed across desktop Chromium, mobile Chromium and mobile WebKit: copying diagnostics, explicit/unmarked reloads, edit/save/load-older/scroll, bounded previews and saved illustration arrival.
  • Production Docker image built and ran successfully. All 24 focused browser checks passed against the bundled Docker app, including a repeat at the final integrated head.
  • Full GitHub Node/browser regression matrix, validation, Docker and CodeQL passed at the final integrated head. CodeRabbit completed through that head with no unresolved findings.

Human verification checklist (intentionally unchecked):

  • Manually verify Copy Support Diagnostics after Refresh App on desktop and mobile.
  • Manually verify generation, editing and older-message scrolling on the physical iPhone Home Screen app.
  • Manually check dark/light appearance and unchanged settings.
  • Review the local event record and its privacy boundaries.

Risk and proof boundaries

  • Entrypoints: existing update/reload actions, error boundary, browser lifecycle/errors, edit completion and illustration receipt.
  • Positive controls: known reload reasons survive navigation; standard error class, minified React code and asset basename/position remain diagnosable.
  • Negative controls: private text/hostnames/unknown stored fields are not copied; duplicate errors do not cause repeated storage writes; an unmarked browser reload is not labeled a crash or GPU failure.
  • Browser tests use disposable synthetic fixtures and no paid provider calls. WebKit emulation is not physical iPhone/PWA verification.
  • An OS-killed or already-dead renderer may leave no final event. Such a gap remains unknown, not proof of a GPU or memory failure. The black-screen cause remains unconfirmed.

Docs and release impact

Unreleased changelog and existing localized Support Diagnostics description updated. No install/update behavior, user-facing docs files, release metadata or translated-doc changes.

UI evidence

Production Docker screenshots, copied synthetic diagnostics and proof notes. Screenshots inspected for the desktop/mobile control and readable Roleplay transcript. No visual redesign; only the existing diagnostics description changes. The report's React code 185 is an intentionally injected test input, not a reproduced app error.


🔄 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/5896 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 9/6/2026 **Status:** ✅ Merged **Merged:** 9/6/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `fix/5870-client-recovery-diagnostics` --- ### 📝 Commits (4) - [`80b81d5`](https://github.com/Pasta-Devs/Marinara-Engine/commit/80b81d5e1ac63050722aae44edbfd84d504dd5a9) docs: scope client recovery diagnostics for #5870 - [`e5186c5`](https://github.com/Pasta-Devs/Marinara-Engine/commit/e5186c54a3c1bc6a52b038fd7c8f28b955326702) feat(client): retain bounded private-safe recovery observations - [`4cd59e4`](https://github.com/Pasta-Devs/Marinara-Engine/commit/4cd59e4115ff28edea50ea07ab1401df09c4fbaf) docs(client): clarify manual export of recovery diagnostics - [`89cadad`](https://github.com/Pasta-Devs/Marinara-Engine/commit/89cadad2cf7bace2373e46704af3f6c3f7f64640) Merge remote-tracking branch 'origin/staging' into fix/5870-client-recovery-diagnostics ### 📊 Changes **15 files changed** (+677 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+1 -0) ➕ `e2e/client-runtime-diagnostics.e2e.ts` (+181 -0) 📝 `packages/client/src/App.tsx` (+6 -3) 📝 `packages/client/src/components/capabilities/CapabilityElement.tsx` (+2 -1) 📝 `packages/client/src/components/chat/ChatMessage.tsx` (+2 -0) 📝 `packages/client/src/components/panels/SettingsPanel.tsx` (+2 -0) 📝 `packages/client/src/hooks/use-generate.ts` (+3 -0) 📝 `packages/client/src/lib/app-update-prompt.ts` (+2 -1) 📝 `packages/client/src/lib/browser-runtime.ts` (+12 -2) ➕ `packages/client/src/lib/client-runtime-diagnostics.ts` (+238 -0) 📝 `packages/client/src/lib/support-diagnostics.ts` (+6 -0) 📝 `packages/client/src/localization/locales/en.json` (+1 -1) 📝 `packages/client/src/main.tsx` (+8 -1) ➕ `scripts/regressions/client-runtime-diagnostics.regression.ts` (+212 -0) 📝 `scripts/regressions/tsconfig.client-lanes.json` (+1 -1) </details> ### 📄 Description ## Linked issue Related to #5870. Keep that issue open: this diagnostic follow-up does not resolve or reproduce the physical-iPhone failure. ## Why this change The maintainer still sees full-page refreshes and intermittent black screens in the installed iPhone app, including after editing and scrolling without image generation. Existing Support Diagnostics reports server health but cannot distinguish an app-requested client reload from an unknown browser interruption. The approved follow-up adds that missing evidence without another speculative rendering workaround. ## What changed - Include the actual frontend build, viewport/root geometry and the last 16 local client events in Copy Support Diagnostics. - Mark existing reload paths, observed JavaScript/React errors, and generic edit/image-arrival milestones. No new automatic reload, polling, scroll listener or network telemetry. - Reconstruct stored records through a strict allowlist; exclude chat text, prompts, image URLs and raw exception messages/stacks. Deduplicate errors and tolerate unavailable/malformed storage. - Preserve appearance settings, original image quality, existing preview bounds and generation recovery behavior. No new dependency or version bump. - Update the canonical English diagnostics description and Unreleased changelog. ## Validation Automated evidence: implementation `e5186c54a`, privacy wording clarification `4cd59e411`, final integrated head `89cadad2cf7bace2373e46704af3f6c3f7f64640` (staging update #5894; no additional client behavior change): - `pnpm install` and `pnpm check` passed (including localization, TypeScript, lint and production build); `pnpm check` passed again at the final integrated head. - Focused Node regression passed: cross-page persistence, privacy, malformed/oversized records, blocked/quota storage, error storms, reload attribution and the existing recovery cooldown. - 24 focused browser checks passed across desktop Chromium, mobile Chromium and mobile WebKit: copying diagnostics, explicit/unmarked reloads, edit/save/load-older/scroll, bounded previews and saved illustration arrival. - Production Docker image built and ran successfully. All 24 focused browser checks passed against the bundled Docker app, including a repeat at the final integrated head. - Full GitHub Node/browser regression matrix, validation, Docker and CodeQL passed at the final integrated head. CodeRabbit completed through that head with no unresolved findings. Human verification checklist (intentionally unchecked): - [ ] Manually verify Copy Support Diagnostics after Refresh App on desktop and mobile. - [ ] Manually verify generation, editing and older-message scrolling on the physical iPhone Home Screen app. - [ ] Manually check dark/light appearance and unchanged settings. - [ ] Review the local event record and its privacy boundaries. ## Risk and proof boundaries - Entrypoints: existing update/reload actions, error boundary, browser lifecycle/errors, edit completion and illustration receipt. - Positive controls: known reload reasons survive navigation; standard error class, minified React code and asset basename/position remain diagnosable. - Negative controls: private text/hostnames/unknown stored fields are not copied; duplicate errors do not cause repeated storage writes; an unmarked browser reload is not labeled a crash or GPU failure. - Browser tests use disposable synthetic fixtures and no paid provider calls. WebKit emulation is not physical iPhone/PWA verification. - An OS-killed or already-dead renderer may leave no final event. Such a gap remains **unknown**, not proof of a GPU or memory failure. The black-screen cause remains unconfirmed. ## Docs and release impact Unreleased changelog and existing localized Support Diagnostics description updated. No install/update behavior, user-facing docs files, release metadata or translated-doc changes. ## UI evidence [Production Docker screenshots, copied synthetic diagnostics and proof notes](https://gist.github.com/SpicyMarinara/c4d70e31c7169eb86ebf0a8ab5a4bc5e). Screenshots inspected for the desktop/mobile control and readable Roleplay transcript. No visual redesign; only the existing diagnostics description changes. The report's React code 185 is an intentionally injected test input, not a reproduced app error. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-23 04:15:30 +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#6988
No description provided.