@cotal-ai/connector-hermes 0.70.0 → 0.71.0
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 +12 -4
- package/dist/launch.js +87 -76
- package/package.json +3 -3
- package/plugin/cotal/_sidecar/standalone.cjs +86 -77
package/dist/index.js
CHANGED
|
@@ -11,10 +11,13 @@ import { fileURLToPath } from "node:url";
|
|
|
11
11
|
import { registry as registry3 } from "@cotal-ai/core";
|
|
12
12
|
|
|
13
13
|
// ../connector-core/dist/config.js
|
|
14
|
-
import { DEFAULT_SERVER, DEV_OWNER, LAUNCH_MATERIAL_ENV, discardLaunchMaterial, assertLifecycleToken, assertValidChannel, channelInAllow, credsClaims, eventChannel, idFromCreds, isConcreteChannel, loadAgentFile, parseJoinLink,
|
|
14
|
+
import { DEFAULT_SERVER, DEV_OWNER, LAUNCH_MATERIAL_ENV as LAUNCH_MATERIAL_ENV2, discardLaunchMaterial, assertLifecycleToken, assertValidChannel, channelInAllow, credsClaims, eventChannel, idFromCreds, isConcreteChannel, loadAgentFile, parseJoinLink, resolveReadAcl } from "@cotal-ai/core";
|
|
15
|
+
|
|
16
|
+
// ../connector-core/dist/session-env.js
|
|
17
|
+
import { LAUNCH_MATERIAL_ENV, readLaunchMaterial } from "@cotal-ai/core/launch-material";
|
|
15
18
|
|
|
16
19
|
// ../connector-core/dist/agent.js
|
|
17
|
-
import { normalizeMentions, RUN_LAUNCH_DEADLINE_MS, subjectMatches, isConcreteChannel as isConcreteChannel2, assertValidChannel as assertValidChannel2, channelInAllow as channelInAllow2, resolvePeer as resolvePeerInRoster, peerLabel as peerLabel2, CotalEndpoint, BASELINE_LIFECYCLE_ENDPOINT as BASELINE_LIFECYCLE_ENDPOINT2, BIND_SPLIT_REISSUES, assertLifecycleToken as assertLifecycleToken3, EpEnvelopeError, isPublishPermissionDenied, unansweredRequest, renderLifecycleBlocked, controlReplyFrom,
|
|
20
|
+
import { normalizeMentions, RUN_LAUNCH_DEADLINE_MS, subjectMatches, isConcreteChannel as isConcreteChannel2, assertValidChannel as assertValidChannel2, channelInAllow as channelInAllow2, resolvePeer as resolvePeerInRoster, peerLabel as peerLabel2, CotalEndpoint, BASELINE_LIFECYCLE_ENDPOINT as BASELINE_LIFECYCLE_ENDPOINT2, BIND_SPLIT_REISSUES, assertLifecycleToken as assertLifecycleToken3, EpEnvelopeError, isPublishPermissionDenied, unansweredRequest, renderLifecycleBlocked, controlReplyFrom, runAgentBearer, partsToText, assertValidRole } from "@cotal-ai/core";
|
|
18
21
|
|
|
19
22
|
// ../connector-core/dist/framing.js
|
|
20
23
|
import { peerLabel } from "@cotal-ai/core";
|
|
@@ -26,7 +29,7 @@ import { BASELINE_LIFECYCLE_ENDPOINT, assertLifecycleToken as assertLifecycleTok
|
|
|
26
29
|
var SUN_PATH_MAX_BYTES = process.platform === "darwin" ? 104 : 108;
|
|
27
30
|
|
|
28
31
|
// ../connector-core/dist/launch.js
|
|
29
|
-
import { eventChannel as eventChannel2, LAUNCH_MATERIAL_ENV as
|
|
32
|
+
import { eventChannel as eventChannel2, LAUNCH_MATERIAL_ENV as LAUNCH_MATERIAL_ENV3, parsePrincipalKey, principalKey, writeLaunchMaterial } from "@cotal-ai/core";
|
|
30
33
|
import { EVENT_CHANNEL_PREFIX, eventChannel as eventChannel3, eventChannelPrincipal, isEventChannel } from "@cotal-ai/core";
|
|
31
34
|
var OS_ENV_ALLOW = [
|
|
32
35
|
"PATH",
|
|
@@ -102,6 +105,11 @@ var OPERATOR_ENV_KEEP = [
|
|
|
102
105
|
"COTAL_ORCA_BIN"
|
|
103
106
|
];
|
|
104
107
|
function launchEnv(opts = {}) {
|
|
108
|
+
for (const k of opts.envAllow ?? []) {
|
|
109
|
+
const name = k.toUpperCase();
|
|
110
|
+
if (name.startsWith("COTAL_") && !OPERATOR_ENV_KEEP.some((keep) => keep === name))
|
|
111
|
+
throw new Error(`spawn.env cannot list "${k}": the launcher sets COTAL_ names for each seat, and only the machine-wide ones such as COTAL_HOME cross from the spawning process`);
|
|
112
|
+
}
|
|
105
113
|
const env = {};
|
|
106
114
|
const sourceKey = /* @__PURE__ */ new Map();
|
|
107
115
|
for (const k of Object.keys(process.env))
|
|
@@ -152,7 +160,7 @@ function materialEnv(opts) {
|
|
|
152
160
|
material.userAuth = opts.userAuth;
|
|
153
161
|
if (Object.keys(material).length === 0)
|
|
154
162
|
return {};
|
|
155
|
-
return { [
|
|
163
|
+
return { [LAUNCH_MATERIAL_ENV3]: writeLaunchMaterial(material) };
|
|
156
164
|
}
|
|
157
165
|
|
|
158
166
|
// ../connector-core/dist/agui.js
|