feat(create): warn on --no-onboard for post-discovered-id agents (Issue #68)

This commit is contained in:
Godopu committed 2026-10-28 15:01:50 +00:00
1 parent 5305cf21f9
commit 3fd2416a30
4 files changed
+136 -2

No files matched your search

@@ -170,7 +170,7 @@ bash .agents/skills/multi-agent-mux-create/scripts/create_session.sh --workspace
| `--herdr-session` (`--herdr-server`) | Isolated herdr server name |
| `--herdr-workspace` | herdr workspace label recorded in the registry (a label only, never a socket) |
| `--submit-job PROMPT` | Register a delegated job with this prompt and send it to the new agent |
| `--onboard` / `--no-onboard` | Submit the onboarding job (default: on) |
| `--onboard` / `--no-onboard` | Submit the onboarding job (default: on); with `--no-onboard` an agent whose id appears only after its first turn (adapter `id_lifecycle`) records none until then and blocks a same-folder create of its type (#63) - create warns |
| `--auto-trust` / `--no-auto-trust` | Answer a start-up directory-trust dialog or leave it to a human (`MAM_AUTO_TRUST`; default: answer) |
| `--isolate` / `--no-isolate` | Legacy, no-op |
@@ -205,6 +205,10 @@ fi
# Retrieve agent facts once
eval "$("$(_delegate_py_bin)" -m lib_py.agents facts "$AGENT" 2>/dev/null || true)"
# Issue #68: warn when --no-onboard is used with a post-discovered-id agent (adapter id_lifecycle via facts).
if [ "$ONBOARD" = 0 ] && [ "${MAM_ID_POST_DISCOVERED:-0}" = 1 ]; then
echo "WARNING: --no-onboard: $AGENT records its conversation id only after its first turn; until then it is not in the registry, and another $AGENT session created in this folder waits for it (Issue #63, MAM_ID_ORDER_WAIT_S)." >&2
fi
CMD_FULL="$("$(_delegate_py_bin)" -m lib_py.agents spawn-spec "$AGENT" "$RESOLVED_BIN" "$SESSION_UUID" "${USE_WRAPPER:-0}" 2>/dev/null || true)"
if [ -z "$CMD_FULL" ]; then