@runuai/host 0.6.0 → 0.6.1
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/lib/agents/transport.ts +18 -1
- package/package.json +1 -1
package/lib/agents/transport.ts
CHANGED
|
@@ -155,7 +155,24 @@ export function createAgentTransport(opts: AgentTransportOptions): LineTransport
|
|
|
155
155
|
// before this feature (the workspace is mounted at its host path) and
|
|
156
156
|
// never skews against the host version.
|
|
157
157
|
const runnerInSession = join(sessionDir, "runner.mjs");
|
|
158
|
-
|
|
158
|
+
try {
|
|
159
|
+
copyFileSync(runnerScriptPath(), runnerInSession);
|
|
160
|
+
} catch (err) {
|
|
161
|
+
// Runner asset missing (a packaging miss — the 0.3.0/0.3.1 desktop
|
|
162
|
+
// builds vendored the agent without runner/). Degrade to legacy pipes:
|
|
163
|
+
// sessions work, they just don't survive host restarts.
|
|
164
|
+
console.warn(
|
|
165
|
+
`[transport] runner unavailable (${err instanceof Error ? err.message : err}) — falling back to direct pipes for ${opts.agentId}`,
|
|
166
|
+
);
|
|
167
|
+
const { command, args } = dockerExecArgs(
|
|
168
|
+
opts.containerName,
|
|
169
|
+
opts.cli,
|
|
170
|
+
opts.cliArgs,
|
|
171
|
+
opts.passEnv ?? [],
|
|
172
|
+
opts.explicitEnv ?? {},
|
|
173
|
+
);
|
|
174
|
+
return new LineProcess({ command, args, debugLabel: opts.debugLabel });
|
|
175
|
+
}
|
|
159
176
|
|
|
160
177
|
const envArgs: string[] = [];
|
|
161
178
|
for (const name of opts.passEnv ?? []) {
|
package/package.json
CHANGED