Repository navigation
refactor(daemon): extract diagnostics initialization from Run - #1602
Conversation
✅ Deploy Preview for images-devsy-sh canceled.
|
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 28 minutes. View limit details
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 |
✅ Deploy Preview for devsydev canceled.
|
|
This pull request does not currently match the merge queue conditions, so it cannot be queued from here. The box comes back if it matches again. |
|
@greptileai review |
|
Coordinator update: CI is green on head 9a22af6, including CI Success. PR is ready. Greptile review was requested at #1602 (comment) and has not posted yet. CodeRabbit CLI repeatedly failed with WebSocket closed; GitHub CodeRabbit returned Review rate limited (not a completed review). No unresolved review threads were present at the last check. Leaving the PR ready for the next cycle to complete reviewer gates. |
[Low impact] The PR appears safe to merge. SummaryExtracts diagnostics setup from
Reviews (1) · Last reviewed commit: "refactor(daemon): extract diagnostics in..." · Reviewed by Greptile |
|
@coderabbitai full review |
|
|
Needs human: CodeRabbit review is unavailable due to OSS quota. The fresh full-review request was rejected (next included review in 28 minutes); its success status is not completed reviewer coverage. Current head remains 9a22af6. CI including CI Success passed, Greptile reviewed this head at 5/5, commit signature is verified, and there are no review threads. Final diff is behavior-preserving with 56 non-test changed lines. Leaving ready and unmerged until actual CodeRabbit coverage is obtained. |
Summary
DaemonCmd.Runinto privateinitDiagnostics(location, locatorPath):startedAtcapture,NewRecorder,Nop()fallback, and locator write.Runkeeps the runtime lock, locator env resolution (still beforeAcquireRuntimeLock), theEventDaemonStartedrecord and status update, and the stopping defer, all in the original order.TestInitDiagnosticsfor the published-locator path and the nop-recorder fallback.Why
Runmixes runtime locking, recorder/locator initialization and patrol lifecycle. A private diagnostics initializer separates setup from lifecycle while preserving lock ownership and all diagnostics semantics. This is the next bounded slice in a file untouched by open PRs or the last three surface-refactor merges.Validation
mise run cli:format: exit 0, no file changes.mise run cli:lint:ci: exit 0. Runs onlygolangci-lint config verify(0 issues). Started after another agent's golangci-lint run cleared; it was blocked by "parallel golangci-lint is running" until then.golangci-lint run ./cmd/internal/...: no findings in changed code. One pre-existinggoconstfinding on the existing"ws-test"literal inagent_daemon_test.go:41; this change adds and removes nows-testoccurrence. Not touched.gofmt -l cmd/internal/clean;go vet ./cmd/internal/clean;go test ./cmd/internal/ -count=1ok.prek run --files cmd/internal/agent_daemon.go cmd/internal/agent_daemon_test.go: all hooks passed, including golangci-lint.CodeRabbit CLI
Failed.
coderabbit review --agent --committed --base-commit 2a0a20255ceb9f4e6c638b95c21311f556d8ba39(merge-base of HEAD and origin/main) returnedConnection failed: WebSocket closed(recoverable) on three attempts, the last running about 700s. No review output was produced. The GitHub CodeRabbit review still gates.Auto-merge
Eligible: yes. Behaviour-preserving internal refactor; 56 non-test changed lines (30 added, 26 removed) in 1 non-test file; no tests removed or weakened.
Next
None for this file.