fix: session start timing and MR type issues
- Add 200ms delay after NewSession before sending keys to fix race condition where shell is not ready (mayor.go, crew.go) - Use merge-request type instead of task for gt mq submit (mq.go) Fixes gt-tulx 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -124,8 +124,9 @@ func startMayorSession(t *tmux.Tmux) error {
|
||||
|
||||
// Launch Claude in a respawn loop - session survives restarts
|
||||
// The startup hook handles 'gt prime' automatically
|
||||
// Use SendKeysDelayed to allow shell initialization after NewSession
|
||||
loopCmd := `while true; do echo "🏛️ Starting Mayor session..."; claude --dangerously-skip-permissions; echo ""; echo "Mayor exited. Restarting in 2s... (Ctrl-C to stop)"; sleep 2; done`
|
||||
if err := t.SendKeys(MayorSessionName, loopCmd); err != nil {
|
||||
if err := t.SendKeysDelayed(MayorSessionName, loopCmd, 200); err != nil {
|
||||
return fmt.Errorf("sending command: %w", err)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user