fix: attach_command from one builder, no kill/start_command, row-less stop, one herdr name rule, registry format 2 (Issue #71) #73
No files matched your search
@@ -106,6 +106,7 @@ if [ "$PURGE" = "1" ]; then
|
||||
trap 'rm -f "$WORKSPACE_ROOT/.mam/purging-$SESSION_NAME"' EXIT
|
||||
fi
|
||||
|
||||
AMBIENT_HERDR_SESSION="${HERDR_SESSION_NAME:-}"
|
||||
if [ -n "$HERDR_SERVER_OPT" ]; then
|
||||
export HERDR_SESSION_NAME="$HERDR_SERVER_OPT"
|
||||
else
|
||||
@@ -116,12 +117,17 @@ fi
|
||||
# Issue #71: a session with no registry row (its create/resume died before
|
||||
# registering it) is closed here - herdr only, the registry is left alone. It
|
||||
# has no agent kind, so --agent is not needed. Only a session herdr runs
|
||||
# inside this workspace is closed; anything else changes nothing.
|
||||
# inside this workspace is closed; anything else changes nothing. With no row
|
||||
# the server is chosen as create_session.sh chose it: --herdr-session, else
|
||||
# the environment's HERDR_SESSION_NAME, else the workspace's server.
|
||||
stop_rowless() {
|
||||
if [ "$PURGE" = "1" ]; then
|
||||
echo "ERROR: session '$SESSION_NAME' not in $AGENT_SESSIONS_YAML; --purge-conversation needs its row. Nothing changed." >&2
|
||||
exit 1
|
||||
fi
|
||||
if [ -z "$HERDR_SERVER_OPT" ] && [ -n "$AMBIENT_HERDR_SESSION" ] && [ "$AMBIENT_HERDR_SESSION" != "default" ]; then
|
||||
export HERDR_SESSION_NAME="$AMBIENT_HERDR_SESSION"
|
||||
fi
|
||||
local info cwd
|
||||
info=$(herdr agent get "$SESSION_NAME" 2>/dev/null) || info=""
|
||||
if [ -z "$info" ]; then
|
||||
@@ -173,7 +179,13 @@ for s in d.get('herdr_sessions', []):
|
||||
'delegate_job_logs_dir': cp.get('delegate_job_logs_dir', '') or ''}))
|
||||
sys.exit(0)
|
||||
sys.exit(7)
|
||||
") || stop_rowless
|
||||
") || MAPPED_RC=$?
|
||||
# 7 = no row; any other failure (registry unreadable) stops as before.
|
||||
[ "${MAPPED_RC:-0}" -ne 7 ] || stop_rowless
|
||||
if [ "${MAPPED_RC:-0}" -ne 0 ]; then
|
||||
echo "ERROR: cannot read the row of '$SESSION_NAME' from $AGENT_SESSIONS_YAML" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# --agent 미지정 시 레지스트리 기록으로 해석 (B-21).
|
||||
# ① row['agent'] → ② 세션명 접미사 → ③ pane.cmd 순. 셋 다 실패하면
|
||||
|
||||
@@ -433,7 +433,7 @@
|
||||
"class": "c",
|
||||
"kind": "diagram",
|
||||
"evidence": [
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:228-242"
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:240-254"
|
||||
],
|
||||
"mismatch": null,
|
||||
"note": "state machine"
|
||||
@@ -504,8 +504,8 @@
|
||||
"class": "a",
|
||||
"evidence": [
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:101",
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:120-176",
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:228-232"
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:123-188",
|
||||
"multi-agent-mux-stop/scripts/stop_session.sh:240-244"
|
||||
],
|
||||
"mismatch": [
|
||||
"T1: the doc offered --force-no-yaml, which no script accepts"
|
||||
@@ -601,7 +601,7 @@
|
||||
"other"
|
||||
],
|
||||
"passthrough": {
|
||||
"1": "multi-agent-mux-stop/scripts/stop_session.sh:367"
|
||||
"1": "multi-agent-mux-stop/scripts/stop_session.sh:379"
|
||||
}
|
||||
},
|
||||
"multi-agent-mux-create/scripts/create_session.sh": {
|
||||
|
||||
Reference in new issue
Block a user