-
Notifications
You must be signed in to change notification settings - Fork 0
Handle missing session ids in pytest steering #672
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Conversation
WalkthroughUpdates PytestFullSuiteHandler to treat missing session_id as a new command, swallowing it without mutating state. With session_id present, it uses per-session state to prevent repeating the last command. Tests added to validate behavior for missing session_id scenarios and ensure no state leakage. Changes
Sequence Diagram(s)sequenceDiagram
actor Client
participant Handler as PytestFullSuiteHandler
participant SessionStore as Per-Session State
Client->>Handler: can_handle(context)
alt session_id missing
Handler-->>Client: True (treat as new command)
else session_id present
Handler->>SessionStore: lookup(session_key)
Handler-->>Client: True/False (dedupe vs new)
end
Client->>Handler: handle(context)
alt session_id missing
Note over Handler: Swallow command<br/>No state mutation
Handler-->>Client: replacement_response{ should_swallow: True }
else session_id present
Handler->>SessionStore: state = setdefault(session_key)
alt same as last_command
Handler-->>Client: replacement_response (deduped)
else new command
Handler->>SessionStore: update last_command
Handler-->>Client: success response
end
end
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Poem
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
🧰 Additional context used📓 Path-based instructions (2)**/*.py📄 CodeRabbit inference engine (AGENTS.md)
Files:
src/**/*.py📄 CodeRabbit inference engine (AGENTS.md)
Files:
🧬 Code graph analysis (2)tests/unit/core/services/tool_call_handlers/test_pytest_full_suite_handler.py (1)
src/core/services/tool_call_handlers/pytest_full_suite_handler.py (2)
🔇 Additional comments (4)
Comment |
Summary
Testing
https://chatgpt.com/codex/tasks/task_e_68ec25089a4c8333a7c641442c526119
Summary by CodeRabbit
Bug Fixes
Tests