@adhdev/daemon-core 0.8.78 → 0.8.80
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.d.ts +2 -1
- package/dist/index.js +23 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +22 -9
- package/dist/index.mjs.map +1 -1
- package/dist/session-host/app-name.d.ts +9 -0
- package/node_modules/@adhdev/session-host-core/package.json +2 -2
- package/package.json +2 -2
- package/src/index.ts +2 -0
- package/src/session-host/app-name.ts +33 -11
package/dist/index.mjs
CHANGED
|
@@ -24836,20 +24836,32 @@ var SessionHostPtyTransportFactory = class {
|
|
|
24836
24836
|
// src/session-host/app-name.ts
|
|
24837
24837
|
var DEFAULT_SESSION_HOST_APP_NAME = "adhdev";
|
|
24838
24838
|
var DEFAULT_STANDALONE_SESSION_HOST_APP_NAME = "adhdev-standalone";
|
|
24839
|
-
function
|
|
24840
|
-
|
|
24841
|
-
throw new Error(
|
|
24842
|
-
`Standalone session-host namespace '${DEFAULT_SESSION_HOST_APP_NAME}' is reserved for the global daemon. Use '${DEFAULT_STANDALONE_SESSION_HOST_APP_NAME}' or another non-default namespace.`
|
|
24843
|
-
);
|
|
24839
|
+
function getReservedStandaloneNamespaceWarning() {
|
|
24840
|
+
return `Standalone session-host namespace '${DEFAULT_SESSION_HOST_APP_NAME}' is reserved for the global daemon. Falling back to '${DEFAULT_STANDALONE_SESSION_HOST_APP_NAME}' for this standalone run.`;
|
|
24844
24841
|
}
|
|
24845
|
-
function
|
|
24842
|
+
function resolveSessionHostAppNameResolution(options = {}) {
|
|
24846
24843
|
const env = options.env || process.env;
|
|
24847
24844
|
const explicit = typeof env.ADHDEV_SESSION_HOST_NAME === "string" ? env.ADHDEV_SESSION_HOST_NAME.trim() : "";
|
|
24848
24845
|
if (explicit) {
|
|
24849
|
-
if (options.standalone
|
|
24850
|
-
|
|
24846
|
+
if (options.standalone && explicit === DEFAULT_SESSION_HOST_APP_NAME) {
|
|
24847
|
+
return {
|
|
24848
|
+
appName: DEFAULT_STANDALONE_SESSION_HOST_APP_NAME,
|
|
24849
|
+
warning: getReservedStandaloneNamespaceWarning(),
|
|
24850
|
+
source: "reserved-standalone-fallback"
|
|
24851
|
+
};
|
|
24852
|
+
}
|
|
24853
|
+
return {
|
|
24854
|
+
appName: explicit,
|
|
24855
|
+
source: "explicit"
|
|
24856
|
+
};
|
|
24851
24857
|
}
|
|
24852
|
-
return
|
|
24858
|
+
return {
|
|
24859
|
+
appName: options.standalone ? DEFAULT_STANDALONE_SESSION_HOST_APP_NAME : DEFAULT_SESSION_HOST_APP_NAME,
|
|
24860
|
+
source: "default"
|
|
24861
|
+
};
|
|
24862
|
+
}
|
|
24863
|
+
function resolveSessionHostAppName(options = {}) {
|
|
24864
|
+
return resolveSessionHostAppNameResolution(options).appName;
|
|
24853
24865
|
}
|
|
24854
24866
|
|
|
24855
24867
|
// src/session-host/runtime-support.ts
|
|
@@ -25512,6 +25524,7 @@ export {
|
|
|
25512
25524
|
resolveChatMessageKind,
|
|
25513
25525
|
resolveDebugRuntimeConfig,
|
|
25514
25526
|
resolveSessionHostAppName,
|
|
25527
|
+
resolveSessionHostAppNameResolution,
|
|
25515
25528
|
runAsyncBatch,
|
|
25516
25529
|
saveConfig,
|
|
25517
25530
|
saveState,
|