Repository navigation
fix: Agents now see the Unity main-thread stall notice even when stderr is not a terminal - #3416
Conversation
Agents read stderr through a pipe, so the spinner is disabled and the 30-second stall notice from the heartbeat was dropped: a command waiting on a blocked Editor main thread looked silent until it finished or the CLI gave up. Notices now fall back to a plain stderr line, at most one per minute so a long stall does not pile up lines; an enabled spinner still shows them in place.
|
No actionable comments were generated in the recent review.
|
| Layer / File(s) | Summary |
|---|---|
Notice behavior cli/common/ui/spinner.go, cli/dispatcher/shared-inputs-stamp.json, cli/project-runner/shared-inputs-stamp.json |
TerminalSpinner adds an injectable clock and notice timestamp. The progress callback sends non-connection messages to Notice. Disabled spinners write notices as lines unless stopped or rate-limited. |
Notice behavior tests cli/common/ui/spinner_test.go |
Tests cover plain-line output, the 60-second interval, notices after Stop, in-place display for enabled spinners, and progress messages without a spinner. |
Priority:
Estimated code review effort: 2 (Simple) | ~10 minutes
Change: Bug fix
Possibly related issues
- Issue 3411 — The change surfaces stall notices as lines when the spinner is disabled, addressing the issue’s silent-wait behavior. The issue’s fail-fast behavior remains outside this change.
Merge Risk: 
Minimal · up to 77164
-
Stall notices are now available on piped stderr. No actionable merge-blocking risk was identified.
Pre-merge checks: 
4 · 
1
-
Failed checks: 1 warning Passed checks: 4 passedFull details: Docstring Coverage
-
Explanation
Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 6 functions across 2 files. (2 skipped: 2 unsupported.)
Resolution
Write docstrings for the functions missing them to satisfy the coverage threshold.
-
Finishing Touches: 💡 1
-
📝 Generate docstrings: 💡
-
- Commit to this branch
- Create a new PR
🧪 Generate unit tests (beta)
-
- Commit to this branch
- Create a new PR
-
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
Comment @coderabbitai help to get the list of available commands.
Integrate upstream hatayama#3412 (4ecde68) and hatayama#3416 (eba0ea4). Keep the Tuanjie-only tloop command, owned size name, skill/help text, and SessionState prefix. Regenerate skill copies, the tool catalog, and shared-input stamps. Validation: - scripts/check-go-cli.sh: all four Go modules and cross-platform builds. - scripts/check-tuanjie.ps1: zero compile errors or warnings; 26 affected EditMode tests passed. - Live Tuanjie checks: temporary size creation/removal and selection restoration; Simulator rejects size changes and reset. - Skill size, asmdef reference policy, file length, and C# complexity checks passed.
Summary
Refs #3411. The Unity-side fail-fast for a command still waiting to start (
MAIN_THREAD_BLOCKED) comes in a separate PR.User Impact
Changes
cli/commonchange.Verification
go test ./ui/... ./unityipc/... ./clicore/...incli/common, including five new spinner tests (plain line, one line per minute, nothing after stop, in-place update with a spinner, progress handler writing the notice without a spinner).gofmt -l,go vet ./..., andgolangci-lint run ./...are clean in all four Go modules;go test ./...passes except tests that bind Unix sockets or create directories under/tmp, which the local sandbox denies (left to CI).