Skip to content

feat: Improve CLI guidance for tool enums, busy errors, and dynamic-code diagnostics#1725

Merged
hatayama merged 5 commits into
v3-betafrom
feat/cli-ux-guidance
Jul 12, 2026
Merged

feat: Improve CLI guidance for tool enums, busy errors, and dynamic-code diagnostics#1725
hatayama merged 5 commits into
v3-betafrom
feat/cli-ux-guidance

Conversation

@hatayama

@hatayama hatayama commented Jul 12, 2026

Copy link
Copy Markdown
Owner

Summary

Group 3 integration PR: merges five child PRs that improve uloop CLI/Unity guidance — clearer enum and keyboard-key errors, richer busy/compile recovery hints, and user-snippet-aligned execute-dynamic-code diagnostics.

Diff scope: 64 files, +2088 / −90 vs v3-beta (5 squash commits on feat/cli-ux-guidance). Intended to equal the union of child PR diffs with no extra changes.

Child PRs

#1720 — feat: List valid tool enum values and suggest keyboard key names

#1720

  • Invalid tool enum strings return Valid values: during Unity-side schema deserialization (B-5).
  • Unknown simulate-keyboard --key values suggest close Input System Key names (Digit3 / Numpad3 for bare 3) (B-6).
  • Evidence: CaseInsensitiveStringEnumConverterTests (3) + KeyboardKeyNameSuggesterTests; simulate-keyboard skill documents digit key naming.

#1721 — feat: Add busy-stall focus rescue and richer server_busy / compile guidance

#1721

  • B-7a: After 5s of persistent server_busy retries, focus Unity once (busy_stall) and restore on exit.
  • B-7b: UNITY_SERVER_BUSY errors include EditorActivity (compile/import/play) and contextual NextActions.
  • B-8: External Scene compile failures get NextActions with EditorSceneManager.OpenScene example and unsaved-change guidance.
  • Evidence: connection_retry_test.go (busy-stall focus), CompileResponseFactoryTests + ToolExecutionEditorReadyPolicyTests (13 passed); scripts/check-go-cli.sh pass.

#1722 — fix: Align execute-dynamic-code diagnostic context with user snippet lines

#1722

  • Line, Column, PointerColumn, and Context share the same user-snippet basis (A-2).
  • Evidence: Post-fix real repro — int e= ; on user line 5 → Line=5, Context L5 shows int e= ; with caret at column 8 (not wrapper using lines). 11 EditMode tests passed.

#1723 — fix: Handle execute-dynamic-code transpiler constraints for static locals and byte casts

#1723

  • CS8421: literal hoister keeps literals inline inside static local function bodies (top-level and nested).
  • CS8820 / CS1503: Hint + Suggestion for static lambdas and Color32 byte casts; SKILL.md updated.
  • Evidence: Top-level static int DoubleSuccess=true, Result=6; Color32 cast workaround verified; 15 EditMode tests passed.

#1724 — fix: Align execute-dynamic-code diagnostic lines after using extraction

#1724

  • Root fix: SourceShaper pads TopLevelBodyBuilder to each statement's original line (blank lines, comments, extracted usings).
  • Evidence (Fable real machine, commit 73f63aaf):
    • using + blank + return → Line=3
    • // setup + using + return → Line=3
    • 2 usings + blank + return → Line=4
    • no using + blank + return → Line=3
    • Regression: gapless using Line=2, static local Success=6, multi-line Debug.Log Line=3
    • 48/48 related EditMode tests passed

Protocol / release

Review request

Please verify the integration diff equals the union of #1720#1724 (no stray commits or unrelated file changes). Final Fable review requested before squash merge to v3-beta.

Test plan

  • Diff audit: git diff v3-beta...feat/cli-ux-guidance matches child PR union
  • CI green on integration PR
  • Spot-check: uloop execute-dynamic-code diagnostic line alignment (using+blank, no-using+blank)
  • Spot-check: top-level static local return Double(3) succeeds

Made with Cursor

Review in cubic

hatayama and others added 5 commits July 12, 2026 15:25
…idance (#1721)

Co-authored-by: Cursor <cursoragent@cursor.com>
…lines (#1722)

Co-authored-by: Cursor <cursoragent@cursor.com>
…cals and byte casts (#1723)

Co-authored-by: Cursor <cursoragent@cursor.com>
…on (#1724)

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

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

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

Next review available in: 30 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

Run ID: 4b9f81d9-a08a-4011-8058-f5b8ca7a5b6c

📥 Commits

Reviewing files that changed from the base of the PR and between 03c656b and 8692219.

⛔ Files ignored due to path filters (14)
  • Assets/Tests/Editor/CaseInsensitiveStringEnumConverterTests.cs.meta is excluded by none and included by none
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeDiagnosticColumnMapperTests.cs.meta is excluded by none and included by none
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeDiagnosticContextBuilderTests.cs.meta is excluded by none and included by none
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeTranspilerConstraintHintsTests.cs.meta is excluded by none and included by none
  • Assets/Tests/Editor/KeyboardKeyNameSuggesterTests.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeDiagnosticColumnMapper.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeDiagnosticContextBuilder.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeTranspilerConstraintHints.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeUserSnippetLines.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/LiteralHoistScopeTracker.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/StaticLocalFunctionHeaderScanner.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/WrappedDynamicCodeUserSnippetExtractor.cs.meta is excluded by none and included by none
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/KeyboardKeyNameSuggester.cs.meta is excluded by none and included by none
  • Packages/src/Editor/ToolContracts/CaseInsensitiveStringEnumConverter.cs.meta is excluded by none and included by none
📒 Files selected for processing (50)
  • .agents/skills/uloop-execute-dynamic-code/SKILL.md
  • .agents/skills/uloop-simulate-keyboard/SKILL.md
  • .claude/skills/uloop-execute-dynamic-code/SKILL.md
  • .claude/skills/uloop-simulate-keyboard/SKILL.md
  • Assets/Tests/Editor/CaseInsensitiveStringEnumConverterTests.cs
  • Assets/Tests/Editor/CompileResponseFactoryTests.cs
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeDiagnosticColumnMapperTests.cs
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeDiagnosticContextBuilderTests.cs
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeExecutionResponseFactoryTests.cs
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeLiteralHoisterTests.cs
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeSourcePreparerTests.cs
  • Assets/Tests/Editor/DynamicCodeToolTests/DynamicCodeTranspilerConstraintHintsTests.cs
  • Assets/Tests/Editor/KeyboardKeyNameSuggesterTests.cs
  • Assets/Tests/Editor/ToolExecutionEditorReadyPolicyTests.cs
  • Packages/src/Editor/Application/UnityCliLoopEditorStateGuard.cs
  • Packages/src/Editor/Application/UnityCliLoopToolBusyException.cs
  • Packages/src/Editor/Application/UnityCliLoopToolExecutionService.cs
  • Packages/src/Editor/Domain/ToolExecutionEditorReadyPolicy.cs
  • Packages/src/Editor/FirstPartyTools/Compile/CompileResponse.cs
  • Packages/src/Editor/FirstPartyTools/Compile/CompileResponseFactory.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCodeExecutionResponseFactory.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeDiagnosticColumnMapper.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeDiagnosticContextBuilder.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeLiteralHoister.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeTranspilerConstraintHints.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/DynamicCodeUserSnippetLines.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/LiteralHoistScopeTracker.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/PreUsingResolver.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/SourceShaper.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/StaticLocalFunctionHeaderScanner.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/WrappedDynamicCodeUserSnippetExtractor.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/DynamicCompilation/WrapperTemplate.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/ExecuteDynamicCodeUseCase.cs
  • Packages/src/Editor/FirstPartyTools/ExecuteDynamicCode/Skill/SKILL.md
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/KeyboardKeyNameSuggester.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/SimulateKeyboardUseCase.cs
  • Packages/src/Editor/FirstPartyTools/SimulateKeyboard/Skill/SKILL.md
  • Packages/src/Editor/Infrastructure/Api/JsonRpcResponseFactory.cs
  • Packages/src/Editor/Infrastructure/Api/ServerBusyErrorData.cs
  • Packages/src/Editor/ToolContracts/CaseInsensitiveStringEnumConverter.cs
  • Packages/src/Editor/ToolContracts/UnityCliLoopTool.cs
  • cli/common/errors/busy_editor_state.go
  • cli/common/errors/busy_editor_state_test.go
  • cli/common/errors/error_envelope.go
  • cli/common/errors/error_envelope_test.go
  • cli/dispatcher/internal/dispatcher/error_envelope_test.go
  • cli/dispatcher/shared-inputs-stamp.json
  • cli/project-runner/internal/projectrunner/connection_retry.go
  • cli/project-runner/internal/projectrunner/connection_retry_test.go
  • cli/project-runner/shared-inputs-stamp.json
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/cli-ux-guidance

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.

@hatayama hatayama merged commit 7318b9d into v3-beta Jul 12, 2026
10 checks passed
@hatayama hatayama deleted the feat/cli-ux-guidance branch July 12, 2026 07:38
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