Skip to content

feat: pause-point round 9 feedback improvements#1967

Merged
hatayama merged 5 commits into
v3-betafrom
feature/pause-point-round9
Jul 23, 2026
Merged

feat: pause-point round 9 feedback improvements#1967
hatayama merged 5 commits into
v3-betafrom
feature/pause-point-round9

Conversation

@hatayama

@hatayama hatayama commented Jul 23, 2026

Copy link
Copy Markdown
Owner

Summary

  • Close pause-point round 8/9 feedback: atomic resume+trigger for paused scenario setup, keyboard recovery after pause-point interruptions, and skill docs for the new workflow / capture API shape.

Feedback mapping

Severity Feedback Resolution
7/10 Scenario setup and arm were separate CLI round-trips; game progressed (gravity/timers) before input; input rejected while paused #1964--resume-play on enable-pause-point --await / await-pause-point: arm confirm → resume → trigger in one call; harness regression-harness-resume-play-paused-arm.sh
6/10 After pause-point interrupt mid-Press, bookkeeping vs device state diverged; delayed queued edges after resume #1965 — dispose pending apply on pause; force-sync stale press latch; simulate-keyboard --action ReleaseAll (paused-tolerant); harness scenarios for interrupt / 5s resume / paused ReleaseAll
3/10 TryGetCapturedValue tuple shape undocumented (CS0030 on first use); Fast-Progressing Games still taught split resume+input #1966 — skills document Pause → build → --await --resume-play --trigger, tuple deconstruct sample, and ReleaseAll recovery

Child PRs (already squash-merged into this branch)

  1. feat: add --resume-play to pause-point await flow #1964feat: add --resume-play to pause-point await flow
  2. fix: recover keyboard key state after pause-point interruption with ReleaseAll #1965fix: recover keyboard key state after pause-point interruption with ReleaseAll
  3. docs: document paused-scenario workflow and TryGetCapturedValue signature in skills #1966docs: document paused-scenario workflow and TryGetCapturedValue signature in skills

User Impact

  • Agents can freeze PlayMode, build a scenario, then resume and fire input in one await call without losing the race to the game clock.
  • After a pause-point interrupts a key press, ReleaseAll restores a clean keyboard state (including while still paused for inspection).
  • Skills state the canonical paused-scenario pattern and the capture helper return type up front.

Changes

  • CLI: --resume-play + ResumePlayResult; trigger skip/failure semantics when resume fails.
  • Unity: pending input-apply disposal on pause, button press-latch force-sync, ReleaseAll action + response ReleasedKeys.
  • Docs/skills: pause-point Fast-Progressing Games rewrite; simulate-keyboard ReleaseAll; regenerated .claude / .agents copies.
  • Regression harnesses for resume-play paused-arm and key-state-after-pause-interruption (3 scenarios).

Verification

  • Child PRs were validated locally (scripts/check-go-cli.sh exit 0, uloop compile 0 err/0 warn, harness runs) — repo CI does not fire on PRs targeting a feature branch; full CI runs on this PR.
  • Harnesses: scripts/regression-harness-resume-play-paused-arm.sh, scripts/regression-harness-key-state-after-pause-interruption.sh
  • scripts/check-go-cli.sh / uloop compile on the child PRs

Review in cubic

hatayama and others added 3 commits July 24, 2026 02:37
Co-authored-by: Cursor <cursoragent@cursor.com>
…eleaseAll (#1965)

Co-authored-by: Cursor <cursoragent@cursor.com>
…ture in skills (#1966)

Co-authored-by: Cursor <cursoragent@cursor.com>
@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Warning

Review limit reached

@hatayama, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 33 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: dd0ad719-f784-4c5c-94f4-0aee73f7de16

📥 Commits

Reviewing files that changed from the base of the PR and between c118b8d and e6c62d7.

📒 Files selected for processing (1)
  • Packages/src/Editor/FirstPartyTools/Common/InputSystem/InputSystemConfiguredUpdateApplier.cs
📝 Walkthrough

Walkthrough

The change adds --resume-play pause-point orchestration, post-arming trigger dispatch, and resume-result reporting. It also adds ReleaseAll keyboard recovery, pause-interruption cleanup, updated tool contracts, tests, documentation, and regression harness coverage.

Changes

Pause-point orchestration

Layer / File(s) Summary
Pause-point contracts and guidance
.agents/skills/uloop-pause-point/SKILL.md, .claude/skills/uloop-pause-point/SKILL.md, Packages/src/Editor/CliOnlyTools~/PausePoint/Skill/SKILL.md
Documents post-arming triggers, --resume-play, captured-value tuple access, trigger restrictions, timeout behavior, and fast-progressing-game workflows.
Resume-play parsing and wait wiring
cli/project-runner/internal/projectrunner/pause_point_*.go, native_command_help.go, list_output.go
Parses and propagates --resume-play, confirms marker arming, resumes paused PlayMode, gates trigger dispatch, and returns ResumePlayResult.
Resume-play execution and validation
cli/project-runner/internal/projectrunner/pause_point_resume_play.go, *_test.go
Implements Status/Play IPC handling and tests successful, skipped, unarmed, and failed resume paths.
Pause-point regression coverage
scripts/regression-harness-resume-play-paused-arm.sh, docs/regression-harness.md
Validates arming during manual pause, resume-result fields, trigger interruption, and cleanup.

Keyboard recovery

Layer / File(s) Summary
Pause interruption cleanup
Packages/src/Editor/FirstPartyTools/Common/InputSystem/*, Packages/src/Editor/FirstPartyTools/SimulateKeyboard/*
Discards queued updates on pause and synchronizes keyboard release and press latches before resume.
ReleaseAll action and response
Packages/src/Editor/FirstPartyTools/SimulateKeyboard/Application/*, SimulateKeyboardUseCase.cs, SimulateKeyboardResponse.cs, UnityCliLoopInputSimulationTypes.cs
Adds ReleaseAll, drains tracked keys, releases device-held keys, permits execution while paused, and returns ReleasedKeys.
Keyboard recovery validation and documentation
Packages/src/Editor/FirstPartyTools/SimulateKeyboard/Skill/SKILL.md, .agents/skills/uloop-simulate-keyboard/SKILL.md, .claude/skills/uloop-simulate-keyboard/SKILL.md, cli/common/tools/default-tools.json, Assets/Tests/*, scripts/regression-harness-key-state-after-pause-interruption.sh
Updates schemas and guidance and verifies clean keyboard state across interruption, pause, recovery, and resume scenarios.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant ProjectRunner
  participant PausePointWait
  participant Unity
  participant Trigger
  ProjectRunner->>PausePointWait: enable-pause-point --await --resume-play --trigger
  PausePointWait->>PausePointWait: confirm marker armed
  PausePointWait->>Unity: Status
  Unity-->>PausePointWait: IsPaused
  PausePointWait->>Unity: Play when paused
  Unity-->>PausePointWait: ResumePlayResult
  PausePointWait->>Trigger: dispatch after resume
  Trigger-->>PausePointWait: TriggerResult
Loading
sequenceDiagram
  participant InputUpdateApplier
  participant KeyboardActionExecutor
  participant KeyboardCleanup
  participant InputSystem
  InputUpdateApplier->>InputUpdateApplier: detect pause
  InputUpdateApplier-->>KeyboardActionExecutor: Paused outcome
  KeyboardActionExecutor->>KeyboardCleanup: release interrupted state
  KeyboardCleanup->>InputSystem: explicit release and latch synchronization
Loading

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 57.97% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and related to the PR’s pause-point feedback improvements.
Description check ✅ Passed The description directly summarizes the same pause-point workflow, recovery, docs, and harness changes in this branch.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/pause-point-round9

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (1)
cli/project-runner/internal/projectrunner/pause_point_resume_play_test.go (1)

306-352: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win

Add a combined not-armed case covering both --resume-play and --trigger together.

Existing not-armed tests exercise resumePlay alone (this test) and triggerCommand alone (TestWaitForPausePointSkipsTriggerWhenNotArmed in pause_point_trigger_test.go), but no test sets both flags simultaneously against a not-armed marker to assert both resumeResult.Error and triggerResult.Error are populated together (pause_point_wait_poll.go lines 60-77).

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@cli/project-runner/internal/projectrunner/pause_point_resume_play_test.go`
around lines 306 - 352, Extend TestWaitForPausePointSkipsResumeWhenNotArmed to
set triggerCommand alongside resumePlay, then assert both resumeResult.Error and
triggerResult.Error are populated while the marker is not enabled. Preserve the
existing assertions that neither action executes and the not-enabled state is
returned.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.agents/skills/uloop-simulate-keyboard/SKILL.md:
- Around line 29-31: Update the command synopsis for the keyboard simulation CLI
to represent --key as optional for ReleaseAll, using conditional or separate
command forms so the no-key recovery command is unambiguous. Apply the same
correction at .agents/skills/uloop-simulate-keyboard/SKILL.md lines 29-31 and
.claude/skills/uloop-simulate-keyboard/SKILL.md lines 29-31; keep the existing
parameter-table behavior unchanged.

In
`@Packages/src/Editor/FirstPartyTools/Common/InputSystem/InputSystemConfiguredUpdateApplier.cs`:
- Around line 134-136: Update the timeout handling around
WatchForPauseDiscardAsync so the linked timeoutCts is not disposed while the
watcher is still using its token: await the watcher’s completion before leaving
the timeoutCts scope, or move the watcher to a lifetime that outlasts
timeoutCts. Preserve the existing pause-discard behavior and cancellation flow.

---

Nitpick comments:
In `@cli/project-runner/internal/projectrunner/pause_point_resume_play_test.go`:
- Around line 306-352: Extend TestWaitForPausePointSkipsResumeWhenNotArmed to
set triggerCommand alongside resumePlay, then assert both resumeResult.Error and
triggerResult.Error are populated while the marker is not enabled. Preserve the
existing assertions that neither action executes and the not-enabled state is
returned.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: bb36d5d9-88f6-48ae-9250-a08b02ef79ef

📥 Commits

Reviewing files that changed from the base of the PR and between e1e3467 and 2b5f370.

⛔ Files ignored due to path filters (2)
  • Assets/Tests/Editor/KeyboardKeyStateServiceTests.cs.meta is excluded by none and included by none
  • Assets/Tests/Editor/UnityCLILoop.Tests.Editor.asmdef is excluded by none and included by none
📒 Files selected for processing (34)
  • .agents/skills/uloop-pause-point/SKILL.md
  • .agents/skills/uloop-simulate-keyboard/SKILL.md
  • .claude/skills/uloop-pause-point/SKILL.md
  • .claude/skills/uloop-simulate-keyboard/SKILL.md
  • Assets/RegressionHarness/KeyStateAfterPauseInterruption/SpaceHoldPoller.cs
  • Assets/Tests/Editor/KeyboardKeyStateServiceTests.cs
  • Assets/Tests/PlayMode/KeyboardInputSimulationResponseFactoryTests.cs
  • Packages/src/Editor/CliOnlyTools~/PausePoint/Skill/SKILL.md
  • Packages/src/Editor/FirstPartyTools/Common/InputSimulation/UnityCliLoopInputSimulationTypes.cs
  • Packages/src/Editor/FirstPartyTools/Common/InputSystem/InputSystemConfiguredUpdateApplier.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/Application/KeyboardKeyState.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/KeyboardInputActionExecutor.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/KeyboardInputMainThreadCleanup.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/KeyboardInputSimulationResponseFactory.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/SimulateKeyboardResponse.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/SimulateKeyboardUseCase.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/Skill/SKILL.md
  • cli/common/tools/default-tools.json
  • cli/project-runner/internal/projectrunner/list_output.go
  • cli/project-runner/internal/projectrunner/list_output_test.go
  • cli/project-runner/internal/projectrunner/native_command_help.go
  • cli/project-runner/internal/projectrunner/native_command_help_test.go
  • cli/project-runner/internal/projectrunner/pause_point_enable.go
  • cli/project-runner/internal/projectrunner/pause_point_enable_test.go
  • cli/project-runner/internal/projectrunner/pause_point_resume_play.go
  • cli/project-runner/internal/projectrunner/pause_point_resume_play_test.go
  • cli/project-runner/internal/projectrunner/pause_point_trigger_test.go
  • cli/project-runner/internal/projectrunner/pause_point_types.go
  • cli/project-runner/internal/projectrunner/pause_point_wait.go
  • cli/project-runner/internal/projectrunner/pause_point_wait_poll.go
  • cli/project-runner/internal/projectrunner/pause_point_wait_test.go
  • docs/regression-harness.md
  • scripts/regression-harness-key-state-after-pause-interruption.sh
  • scripts/regression-harness-resume-play-paused-arm.sh

Comment thread .agents/skills/uloop-simulate-keyboard/SKILL.md
Cancel the apply timeout CTS on the timeout path so the pause watcher
stops instead of polling a disposed token. Clarify ReleaseAll synopsis
and cover the combined not-armed resume+trigger skip path.

Co-authored-by: Cursor <cursoragent@cursor.com>
@hatayama

Copy link
Copy Markdown
Owner Author

Addressed CodeRabbit review items in c118b8d:

  1. simulate-keyboard SKILL synopsis — separate ReleaseAll form (source + regenerated copies)
  2. InputSystemConfiguredUpdateAppliertimeoutCts.Cancel() on the timeout path
  3. Nitpick — added TestWaitForPausePointSkipsResumeAndTriggerWhenNotArmed covering combined not-armed --resume-play + --trigger

Local verification: scripts/check-go-cli.sh exit 0, uloop compile 0 errors (pre-existing CS8602 elsewhere in the same file unchanged), key-state harness scenarios 1–3 exit 0.

@hatayama

Copy link
Copy Markdown
Owner Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 23, 2026

Copy link
Copy Markdown
Contributor
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Co-authored-by: Cursor <cursoragent@cursor.com>
@hatayama
hatayama merged commit 1ea3696 into v3-beta Jul 23, 2026
12 checks passed
@hatayama
hatayama deleted the feature/pause-point-round9 branch July 23, 2026 18:55
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