fix(runner): prevent Gemini CLI exit 42 on workflow add#893
fix(runner): prevent Gemini CLI exit 42 on workflow add#893Gkrumbach07 merged 2 commits intomainfrom
Conversation
WalkthroughThe changes add session ID cleanup functionality to the Gemini CLI bridge. A new Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
When a workflow is added mid-session, the CWD changes but old session IDs persist on disk. Gemini CLI fails to resume the old session in the new CWD and exits with code 42. Now clear session IDs when mark_dirty is triggered by a workflow change. - Add clear_session_ids() method to GeminiSessionManager - Call it from mark_dirty() before shutting down the manager - Uses EAFP pattern (try/except) to avoid TOCTOU race conditions Fixes: RHOAIENG-52260 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Remove executable bit from bridge.py, session.py, and test file - Files should be 644 (rw-r--r--), not 755 (rwxr-xr-x) Co-Authored-By: Claude <noreply@anthropic.com>
6d2df33 to
39ebe00
Compare
PR Fixer Report✅ Rebase Status
📝 Review FeedbackNo inline review comments to address. CodeRabbit hit rate limits before posting a review. 🔍 Code ReviewRan
🛠️ Fixes Applied
✅ CI StatusAll CI checks passed on the original commit:
📤 Commits Pushed
The PR is ready for review and merge. |
Summary
clear_session_ids()toGeminiSessionManagerto clear stale session IDs from diskmark_dirty()when workflow changes trigger reinitialisationTest plan
Fixes: RHOAIENG-52260
🤖 Generated with Claude Code
Jira: RHOAIENG-52260