File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ import { runIosRunnerCommand } from '../../platforms/ios/runner-client.ts';
77import type { DaemonRequest , DaemonResponse , SessionState } from '../types.ts' ;
88import { SessionStore } from '../session-store.ts' ;
99import { ensureDeviceReady } from '../device-ready.ts' ;
10+ import { emitDiagnostic } from '../../utils/diagnostics.ts' ;
1011
1112function getRunnerOptions ( req : DaemonRequest , logPath : string | undefined , session : SessionState ) {
1213 return {
@@ -112,7 +113,18 @@ export async function handleRecordTraceCommands(params: {
112113 { command : 'recordStop' , appBundleId : activeSession . appBundleId } ,
113114 getRunnerOptions ( req , logPath , activeSession ) ,
114115 ) ;
115- } catch {
116+ } catch ( error ) {
117+ emitDiagnostic ( {
118+ level : 'warn' ,
119+ phase : 'record_stop_runner_failed' ,
120+ data : {
121+ platform : device . platform ,
122+ kind : device . kind ,
123+ deviceId : device . id ,
124+ session : activeSession . name ,
125+ error : error instanceof Error ? error . message : String ( error ) ,
126+ } ,
127+ } ) ;
116128 // best effort: clear runner-backed recording state even if runner stop fails
117129 }
118130 } else {
You can’t perform that action at this time.
0 commit comments