fix: pre-emptive aoe rm --purge to prevent stale cmd-override on re-dispatch#5
Merged
Conversation
…rride aoe rm (without --purge) leaves the session record with a stale command: field, so aoe add for the same title re-registers silently with the OLD command. Now we purge first, best-effort — if the session doesn't exist, aoe rm exits non-zero and we carry on. Closes: #4
setup-uv v8 dropped moving tags (@v8 doesn't exist). Pin to the specific commit hash for v8.3.2 as recommended by upstream docs.
mypy was failing on in events.py because the stub package wasn't installed. Pre-existing issue, previously hidden by the setup-uv@v8 CI config bug.
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
Closes
bogocat/tmq#4. The prior commitedaaf47fixed the spawned argv bugs (#1 empty-argwt_flagand #2 missing--approve). This adds the third fix: a best-effortaoe rm --purgebeforeaoe addso re-dispatching always picks up the newcmd-override.What changed
src/tmq/spawn.py(~14 lines): In_spawn_via_aoe, runaoe rm --purge <session_name>withcheck=Falsebeforeaoe add. If the session does not exist,aoe rmexits non-zero — we catch theSpawnErrorand carry on. The subsequentaoe addwill surface any real error.tests/test_spawn.py(+30 lines): New testtest_spawn_via_aoe_purges_before_addthat captures the full_runcall sequence and assertsaoe rm --purgefires beforeaoe add. New helper_captured_aoe_call_sequencefor sequence-ordered assertions.Out of scope
--trust-hookssemantics (closed Rust binary)--approvebehavior (upstream)pip installaoe/tmuxspawns yetReview
Single-reviewer scan — net change is ~14 lines of production code with a targeted unit test.
Test plan
python3 -m pytest tests/test_spawn.py -v # 10/10 passVerification
tmq distillery 558 --agent pi --type featurestill works — run manually after mergeFollow-ups
bogocat/tower-fleet#202pip install --upgrade bogocat-tmq