Skip to content

BDSP AutoStory: save each failed event's stream history - #309

Draft
dayfine wants to merge 11 commits into
bdsp/autostory-v4from
bdsp/autostory-failure-capture
Draft

dayfine wants to merge 11 commits into
bdsp/autostory-v4from
bdsp/autostory-failure-capture

Conversation

@dayfine

@dayfine dayfine commented Nov 9, 2026

Copy link
Copy Markdown
Owner

Depends on #308. Base bdsp/autostory-v4 (#128) with #308 merged in, so the diff also shows #308 until it lands in nav/story-steps and is merged down.

BDSP AutoStory failures on console B left only the last screenshot: they throw with NO_ERROR_REPORT, so ErrorReportsLocal stays empty, and a retry resets the game before the failure is saved. The executor now attaches #308's FailureCapture to its story hooks (normal runs and verify mode), so each failed attempt saves USER_FILE_PATH()/PokemonBDSP/AutoStoryFailures/<time>-<checkpoint>-<event>/ (Video.mp4, Screenshot.png, Failure.json) before the reset, and a run that throws saves under the last step under way. Built and compiled locally; Pokemon::StorySegments and Pokemon::AutoStoryFailureCapture pass in the headless runner; not yet run on console B.

🤖 Generated with Claude Code

https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss

dayfine and others added 11 commits November 9, 2026 10:58
A story failure throws with NO_ERROR_REPORT, so no error report (and no
Video.mp4) was written for it, and a retry reloaded the game before anyone
saw the failure frame. SegmentHooks gets a `failed` hook, told of each failed
attempt and verify run before any reload. FailureCapture attaches to it and
saves USER_FILE_PATH()/<game>/AutoStoryFailures/<time>-<checkpoint>-<event>/
with Video.mp4 (stream history), Screenshot.png and Failure.json, whatever
the error-report send mode; save_thrown() covers exceptions out of the run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
FailureCapture is attached to the story hooks, so each failed attempt and
verify run saves its video, screenshot and JSON before the reload, and a
run that throws saves under the last step under way.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
The unit-test runner's registration function is at its length limit on the
game stacks.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Conflicts: the run_segment() and verify_checkpoint() calls take the
core's outputs-last order and keep the capture of a thrown failure;
StorySegments.cpp keeps tell_failed() before the say(). Test headers
are one per suite now, so add_tests_AutoStoryFailureCapture() is
declared in its own Pokemon_AutoStoryFailureCapture_Tests.h, still
registered by add_tests_StorySegments().

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013VUubhHeYSMGSSDXZkKZss
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant