feat(ralph-loop): timestamp log filenames per session
Log files are now named <YYYYMMDDTHHMMSS>-iteration-N.log instead of iteration-N.log. Each ralph-loop.sh invocation gets a unique SESSION_TS so restarting after a session reset no longer overwrites previous logs. Full audit trail preserved across resets. Agent: human Tests: N/A Tests-Added: 0 TypeScript: N/A
This commit is contained in:
parent
8510eacecb
commit
35008b9782
|
|
@ -37,6 +37,7 @@ SPEC_FILE="PROJECT-SPEC.md"
|
|||
AGENT_FILE="AGENT.md"
|
||||
BOARD_FILE=""
|
||||
LOG_DIR=".ralph-logs"
|
||||
SESSION_TS="$(date '+%Y%m%dT%H%M%S')"
|
||||
RATE_LIMIT_WAIT=1800
|
||||
SESSION_ENDS=""
|
||||
REQUIRE_PRO=1
|
||||
|
|
@ -349,7 +350,7 @@ wait_for_tokens() {
|
|||
run_agent() {
|
||||
local iteration=$1
|
||||
local mode=$2
|
||||
local logfile="$LOG_DIR/iteration-${iteration}.log"
|
||||
local logfile="$LOG_DIR/${SESSION_TS}-iteration-${iteration}.log"
|
||||
local prompt=""
|
||||
|
||||
if [[ "$mode" == "plan" ]]; then
|
||||
|
|
@ -489,7 +490,7 @@ echo ""
|
|||
|
||||
for i in $(seq 1 "$MAX_ITERATIONS"); do
|
||||
run_agent "$i" build
|
||||
logfile="$LOG_DIR/iteration-${i}.log"
|
||||
logfile="$LOG_DIR/${SESSION_TS}-iteration-${i}.log"
|
||||
|
||||
status=0; check_output "$logfile" || status=$?
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue