fix(ext): !stop getActiveSessionId stale primitive — use step-probe getter #task-410

This commit is contained in:
Variet Worker
2026-03-18 08:34:58 +09:00
parent 07bbb626a6
commit ab0c116c9e
3 changed files with 79 additions and 67 deletions

View File

@@ -16,7 +16,7 @@ import * as path from 'path';
import * as os from 'os';
import * as cp from 'child_process';
import { WSBridgeClient, WSResponseData, WSCommandData } from './ws-client';
import { initStepProbe, BridgeContext, writePendingApproval, tryApprovalStrategies, writeRegistration, getApprovalContext, resetPendingState, handleDiffReviewResponse } from './step-probe';
import { initStepProbe, BridgeContext, writePendingApproval, tryApprovalStrategies, writeRegistration, getApprovalContext, resetPendingState, handleDiffReviewResponse, getActiveSessionId as getStepProbeSessionId } from './step-probe';
import { startHttpBridge, getDeterministicPort, HttpBridgeContext } from './http-bridge';
import { setupApprovalObserver } from './html-patcher';
import { watchCommandsDir, handleWSCommand, disposeCommandsWatcher, CommandHandlerContext } from './command-handler';
@@ -430,7 +430,7 @@ export async function activate(context: vscode.ExtensionContext) {
bridgePath, projectName, sdk, ls: sdk?.ls, autoApproveEnabled, logToFile,
onAutoApproveChanged: (enabled: boolean) => { autoApproveEnabled = enabled; },
recentDiscordSentTexts,
getActiveSessionId: () => activeSessionId,
getActiveSessionId: () => getStepProbeSessionId(),
}, data);
},
onInstanceUpdate: (count, instances) => {
@@ -560,7 +560,7 @@ export async function activate(context: vscode.ExtensionContext) {
bridgePath, projectName, sdk, ls: sdk?.ls, autoApproveEnabled, logToFile,
onAutoApproveChanged: (enabled: boolean) => { autoApproveEnabled = enabled; },
recentDiscordSentTexts,
getActiveSessionId: () => activeSessionId,
getActiveSessionId: () => getStepProbeSessionId(),
});
// Response watcher is now initialized by initStepProbe() above