The best way to control Claude Code, Codex and more from any computer or phone
perf(server): stop tracing the per-event background-work probe (#31584)
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Julius Marminge committed
Nov 6, 2026 at 11:55 UTC
50f0dacbd7695309a58d69318fab2fff502a91ea
2 files changed
+4
-6
apps/server/src/orchestration-v2/Adapters/ClaudeAdapterV2.ts
+2
-3
@@ -11809,9 +11809,8 @@ export const makeClaudeAdapterV2 = Effect.fn("makeClaudeAdapterV2")(function* (
11809
}
11810
return false;
11811
}),
11812
- hasPendingBackgroundWorkForThread: Effect.fn(
11813
- "ClaudeAdapterV2.hasPendingBackgroundWorkForThread",
11814
- )(function* (providerThread, options) {
11812
+ // Untraced: the run's event stream calls this once per provider event.
11813
+ hasPendingBackgroundWorkForThread: Effect.fnUntraced(function* (providerThread, options) {
11814
const nativeThreadId = providerThread.nativeThreadRef?.nativeId;
11815
if (nativeThreadId === undefined || nativeThreadId === null) {
11816
return false;
apps/server/src/orchestration-v2/Adapters/CodexAdapterV2.ts
+2
-3
@@ -7071,9 +7071,8 @@ export const makeCodexAdapterV2 = Effect.fn("makeCodexAdapterV2")(function* (
7071
}
7072
return false;
7073
}),
7074
- hasPendingBackgroundWorkForThread: Effect.fn(
7075
- "CodexAdapterV2.hasPendingBackgroundWorkForThread",
7076
- )(function* (providerThread) {
7074
+ // Untraced: the run's event stream calls this once per provider event.
7075
+ hasPendingBackgroundWorkForThread: Effect.fnUntraced(function* (providerThread) {
7076
const contexts = [
7077
...(yield* Ref.get(activeTurns)).values(),
7078
...(yield* Ref.get(settledTurns)).values(),