@rallycry/conveyor-agent 10.2.5 → 10.3.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/dist/{chunk-CFELRV35.js → chunk-HAH2S5AD.js} +208 -60
- package/dist/chunk-HAH2S5AD.js.map +1 -0
- package/dist/cli.js +14 -39
- package/dist/cli.js.map +1 -1
- package/dist/index.d.ts +18 -16
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/runtime/entrypoint.sh +15 -1
- package/dist/chunk-CFELRV35.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -282,23 +282,24 @@ declare class ModeController {
|
|
|
282
282
|
/** Resolve the initial mode based on task context */
|
|
283
283
|
resolveInitialMode(context: ModeTaskContext): AgentMode;
|
|
284
284
|
/**
|
|
285
|
-
*
|
|
286
|
-
*
|
|
287
|
-
*
|
|
288
|
-
*
|
|
289
|
-
*
|
|
285
|
+
* An auto task that still NEEDS PLANNING (no plan saved, pre-build status, no
|
|
286
|
+
* PR — see `taskNeedsPlanning` in @project/shared) runs the read-only plan turn
|
|
287
|
+
* first (`--permission-mode plan`): resolveInitialMode leaves it in `auto` with
|
|
288
|
+
* `_hasExitedPlanMode = false`, and once the agent finishes it calls
|
|
289
|
+
* ExitPlanMode → building. Everything else bypasses planning and builds
|
|
290
|
+
* immediately with `--dangerously-skip-permissions`:
|
|
290
291
|
*
|
|
291
|
-
* - a
|
|
292
|
-
* - a
|
|
293
|
-
* -
|
|
294
|
-
* - a
|
|
292
|
+
* - a plan already on the card (e.g. a Planning card planned by a human/PM),
|
|
293
|
+
* - a build already underway (status past `Planning`/`Open` — releases booted
|
|
294
|
+
* `InProgress`, pod restarts mid-build where DB `agentMode` stays `"auto"`),
|
|
295
|
+
* - a PR already open (safety net if status lags).
|
|
295
296
|
*
|
|
296
297
|
* Runtime Build-after-Discovery never reaches this gate as `auto` — the server's
|
|
297
|
-
* `resolveModeToSend` rewrites it to `"building"` for any
|
|
298
|
+
* `resolveModeToSend` rewrites it to `"building"` for any task with a plan.
|
|
298
299
|
*/
|
|
299
300
|
canBypassPlanning(context: ModeTaskContext): boolean;
|
|
300
301
|
/** Handle mode change from server */
|
|
301
|
-
handleModeChange(newMode: AgentMode): ModeAction;
|
|
302
|
+
handleModeChange(newMode: AgentMode, context?: ModeTaskContext | null): ModeAction;
|
|
302
303
|
/** Handle ExitPlanMode call from the agent */
|
|
303
304
|
handleExitPlanMode(context: ModeTaskContext): ModeAction;
|
|
304
305
|
/** Check if pack runner behavior should be used */
|
|
@@ -537,11 +538,12 @@ declare class SessionRunner {
|
|
|
537
538
|
* help) it's waiting on a human, not silently stuck.
|
|
538
539
|
*
|
|
539
540
|
* - "pr": In Progress with no open PR (build finished without shipping).
|
|
540
|
-
* - "planning": still
|
|
541
|
-
* agent that finishes its plan turn
|
|
542
|
-
* → clean-exit → its session Ends
|
|
543
|
-
* before a plan ever landed. Nudging
|
|
544
|
-
* keeps the session Active so the pod
|
|
541
|
+
* - "planning": still in a pre-build status (Planning/Open) without
|
|
542
|
+
* (identified + saved plan). A fresh auto agent that finishes its plan turn
|
|
543
|
+
* WITHOUT ExitPlanMode would otherwise idle → clean-exit → its session Ends
|
|
544
|
+
* → the workspace is reaped "agent_gone" before a plan ever landed. Nudging
|
|
545
|
+
* (and, on exhaustion, going dormant) keeps the session Active so the pod
|
|
546
|
+
* is never prematurely slept.
|
|
545
547
|
*/
|
|
546
548
|
private autoStuckKind;
|
|
547
549
|
private isAutoStuck;
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rallycry/conveyor-agent",
|
|
3
|
-
"version": "10.
|
|
3
|
+
"version": "10.3.1",
|
|
4
4
|
"description": "Conveyor Agent Runner v10 - PTY harness for the task chat (SDK harness for audit/project-chat). Agent-as-User architecture with BaseService patterns. Works locally too.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"agent",
|
package/runtime/entrypoint.sh
CHANGED
|
@@ -217,10 +217,16 @@ if [ "${SESSION_MODE}" = "review" ]; then
|
|
|
217
217
|
# branch), so a role check can't identify them — gating on role=reader here
|
|
218
218
|
# is what let review pods fall through to the default task runner and boot
|
|
219
219
|
# the parent's task agent in discovery mode. The agent CLI's RunnerMode is
|
|
220
|
-
# spelled "code-review" (cli.ts validates task|pm|code-review|adhoc); the bare
|
|
220
|
+
# spelled "code-review" (cli.ts validates task|pm|code-review|adhoc|pack); the bare
|
|
221
221
|
# "review" is the agentMode/tag axis, NOT a runner mode — passing it here
|
|
222
222
|
# made the agent exit "Invalid CONVEYOR_MODE" and crash-loop every 10s.
|
|
223
223
|
export CONVEYOR_MODE="code-review"
|
|
224
|
+
elif [ "${SESSION_MODE}" = "pack" ]; then
|
|
225
|
+
# Parent-card orchestrator (task-bound — CONVEYOR_TASK_ID is set): the agent
|
|
226
|
+
# runs the autonomous pack loop (start ready children, merge child PRs,
|
|
227
|
+
# complete the parent) instead of building code. Same task-mode lifecycle,
|
|
228
|
+
# different prompt/tool surface — see conveyor-agent pack-runner-prompt.ts.
|
|
229
|
+
export CONVEYOR_MODE="pack"
|
|
224
230
|
elif [ "${SESSION_MODE}" = "adhoc" ]; then
|
|
225
231
|
# Task-less USER SCRATCH pod (Sessions view): the agent runs an interactive
|
|
226
232
|
# `claude` TUI relayed to the web terminal — no autonomous loop, no task. Must
|
|
@@ -312,6 +318,14 @@ seed_claude_json() {
|
|
|
312
318
|
# back to PROJECT_ID from the pod env.
|
|
313
319
|
USER_HOME_MOUNT="/mnt/conveyor-users"
|
|
314
320
|
USER_HOME_PROJECT_ID="${CONVEYOR_PROJECT_ID_FROM_BUNDLE:-${PROJECT_ID:-}}"
|
|
321
|
+
|
|
322
|
+
# Bake steps that run as root while ENV HOME points at /home/conveyor can leave
|
|
323
|
+
# root-owned $HOME entries (a uv install receipt in ~/.config once bricked every
|
|
324
|
+
# pod boot fleet-wide); reclaim them before the symlink work below so a baked
|
|
325
|
+
# ownership slip cannot EACCES the entrypoint under `set -e`. Runs before any
|
|
326
|
+
# symlinks exist, so there is nothing to follow into the FUSE mount.
|
|
327
|
+
sudo -n chown -R conveyor:conveyor /home/conveyor/.config /home/conveyor/.local 2>/dev/null || true
|
|
328
|
+
|
|
315
329
|
if [ -n "${CONVEYOR_USER_ID}" ] && [ -n "${USER_HOME_PROJECT_ID}" ] && [ -d "${USER_HOME_MOUNT}" ]; then
|
|
316
330
|
USER_HOME_ROOT="${USER_HOME_MOUNT}/users/${CONVEYOR_USER_ID}/${USER_HOME_PROJECT_ID}"
|
|
317
331
|
echo "[pool] Linking Claude state to ${USER_HOME_ROOT}"
|