@adhdev/daemon-core 0.9.76-rc.27 → 0.9.76-rc.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +6 -3
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6 -3
- package/dist/index.mjs.map +1 -1
- package/dist/repo-mesh-types.d.ts +1 -0
- package/package.json +1 -1
- package/src/commands/handler.ts +13 -4
- package/src/repo-mesh-types.ts +1 -0
|
@@ -53,6 +53,7 @@ export interface RepoMeshNodePolicy {
|
|
|
53
53
|
readOnly?: boolean;
|
|
54
54
|
canPush?: boolean;
|
|
55
55
|
maxConcurrentSessions?: number;
|
|
56
|
+
/** Ordered provider preference used when mesh_launch_session omits an explicit type. */
|
|
56
57
|
providerPriority?: string[];
|
|
57
58
|
}
|
|
58
59
|
export declare const DEFAULT_MESH_POLICY: RepoMeshPolicy;
|
package/package.json
CHANGED
package/src/commands/handler.ts
CHANGED
|
@@ -303,14 +303,15 @@ export class DaemonCommandHandler implements CommandHelpers {
|
|
|
303
303
|
const sessionLookupFailed = !!targetSessionId && !session;
|
|
304
304
|
|
|
305
305
|
const managerKey = this.extractIdeType(args, sessionLookupFailed);
|
|
306
|
-
let providerType: string | undefined;
|
|
306
|
+
let providerType: string | undefined = args?.agentType || args?.providerType;
|
|
307
307
|
|
|
308
308
|
if (!sessionLookupFailed) {
|
|
309
309
|
providerType =
|
|
310
310
|
session?.providerType
|
|
311
|
-
||
|
|
312
|
-
|| args?.providerType
|
|
311
|
+
|| providerType
|
|
313
312
|
|| this.inferProviderType(managerKey);
|
|
313
|
+
} else if (!providerType) {
|
|
314
|
+
providerType = this.inferProviderType(managerKey);
|
|
314
315
|
}
|
|
315
316
|
|
|
316
317
|
return { session, managerKey, providerType, sessionLookupFailed };
|
|
@@ -407,7 +408,15 @@ export class DaemonCommandHandler implements CommandHelpers {
|
|
|
407
408
|
'invoke_provider_script',
|
|
408
409
|
]);
|
|
409
410
|
|
|
410
|
-
|
|
411
|
+
const allowsInactiveReadChatFallback =
|
|
412
|
+
cmd === 'read_chat'
|
|
413
|
+
&& !!this._currentRoute.providerType
|
|
414
|
+
&& (
|
|
415
|
+
(typeof args?.providerSessionId === 'string' && args.providerSessionId.trim().length > 0)
|
|
416
|
+
|| (typeof args?.historySessionId === 'string' && args.historySessionId.trim().length > 0)
|
|
417
|
+
);
|
|
418
|
+
|
|
419
|
+
if (this._currentRoute.sessionLookupFailed && sessionScopedCommands.has(cmd) && !allowsInactiveReadChatFallback) {
|
|
411
420
|
const result = {
|
|
412
421
|
success: false,
|
|
413
422
|
error: `Live session not found for targetSessionId: ${String(args?.targetSessionId || '').trim() || 'unknown'}`,
|
package/src/repo-mesh-types.ts
CHANGED