Skip to content

Commit 1883fc2

Browse files
committed
fix: propagate request id through daemon context
1 parent 4b34027 commit 1883fc2

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/daemon/context.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import type { CommandFlags } from '../core/dispatch.ts';
2+
import { getDiagnosticsMeta } from '../utils/diagnostics.ts';
23

34
export type DaemonCommandContext = {
45
requestId?: string;
@@ -28,8 +29,9 @@ export function contextFromFlags(
2829
traceLogPath?: string,
2930
requestId?: string,
3031
): DaemonCommandContext {
32+
const effectiveRequestId = requestId ?? getDiagnosticsMeta().requestId;
3133
return {
32-
requestId,
34+
requestId: effectiveRequestId,
3335
appBundleId,
3436
activity: flags?.activity,
3537
verbose: flags?.verbose,

0 commit comments

Comments
 (0)