chore: background-launcher wrapper for run_debate_cycle() - #552
Open
essentialbit wants to merge 3 commits into
Open
chore: background-launcher wrapper for run_debate_cycle()#552essentialbit wants to merge 3 commits into
essentialbit wants to merge 3 commits into
Conversation
The Bash tool call to run_debate_cycle() needs an explicit >=300000ms timeout (Gemini-429/Ollama-fallback retries run long) -- forgotten 4 times despite being documented, silently backgrounding the call each time. This launches the cycle detached so the invoking call returns immediately regardless, with results read back via --check.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
debate.run_debate_cycle()needs a >=300000ms Bash-tool timeout (Gemini-429/Ollama-fallback retry chains run long) -- documented infredai.mdand inlined insensor-prompt.md, but forgotten 4 separate times, each silently backgrounding the call.scripts/run_debate_background.py: launches the cycle as a detached background process so the invoking Bash call returns in well under the 120s default regardless of whether a timeout param was set, logs to~/.claude/fred-sensor/logs/debate_cycle_<ts>.log, and a--check <log> --wait Nmode polls that log for the result.check_sensor_health.py/eligible_backlog.py/etc.) -- pure infrastructure fix for a documented recurring friction, not a debated feature.Test plan
--check <log> --wait 120in a separate call: correctly polled and printed the completedrun_debate_cycle()JSON result (issues_checked: 42, stances_posted: 0, errors: 0) once the background process finished.python3 -c "from main import app"import check unaffected (no changes outsidescripts/).🤖 Generated with Claude Code