Fix concurrent session tag updates targeting the wrong tag - #65
Open
blast-hardcheese wants to merge 1 commit into
Open
blast-hardcheese wants to merge 1 commit into
blast-hardcheese wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Confidence Score: 4/5
Summary
Requires explicit tags to prevent cross-session mutations; 2,913 tests pass. Remaining risks are misleading CLI exit codes and stale agent instructions.
Important Files Changed
| File | Overview |
|---|---|
| README.md | Adds explicit tag names to lifecycle examples |
| docs/mcp-agent-guide.md | Documents mandatory tag names |
| src/kindex/cli.py | Rejects unnamed mutations but exits successfully |
| src/kindex/mcp_server.py | Rejects missing or blank tag names |
| tests/test_mcp.py | Covers unnamed mutation refusal and explicit-name isolation |
| tests/test_sessions.py | Tests unnamed CLI rejection without asserting failure exit status |
Findings
- Update CLAUDE.md:81 and AGENTS.md:81 to include tag names; their update, segment, and end examples now always fail.
| if action in {"update", "segment", "pause", "end"} and not tag_name: | ||
| print(f"Error: kin tag {action} requires an explicit tag name.", file=sys.stderr) | ||
| store.close() | ||
| return |
There was a problem hiding this comment.
Rejected unnamed commands exit 0, so scripts treat lifecycle no-ops as successful; exit nonzero and assert failure status in the new tests.
This branch has not been deployed
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
Verification
wander-serialized-test -- env PYTHONPATH=/Users/dstewart/Projects/kindex/fork-session-bugfix/src /Users/dstewart/Projects/kindex/main/.venv/bin/python -m pytest tests/test_mcp.py tests/test_sessions.py -q— 150 passed.git diff --check— clean.The full test suite will run in CI.