chenhg5/cc-connect · error
reasonix: start session: %w
Error message
reasonix: start session: %w
What it means
A thin wrapper in reasonix Agent.StartSession around newSession failures: creating the HTTP/SSE session against the reasonix serve instance failed (network unreachable, /new rejected, SSE setup error). The wrapped error carries the actual cause.
Source
Thrown at agent/reasonix/reasonix.go:84
case "yolo", "auto", "force":
return "yolo"
case "plan":
return "plan"
default:
return "default"
}
}
func (a *Agent) Name() string { return "reasonix" }
// StartSession creates a session connected to reasonix serve.
// It establishes an SSE connection to /events and waits for it to be ready.
func (a *Agent) StartSession(ctx context.Context, sessionID string) (core.AgentSession, error) {
slog.Info("reasonix: starting session", "session_id", sessionID)
s, err := newSession(ctx, a.serveURL, a.workDir, sessionID, a.mode)
if err != nil {
return nil, fmt.Errorf("reasonix: start session: %w", err)
}
return s, nil
}
// ListSessions returns nil because reasonix doesn't expose session listing.
func (a *Agent) ListSessions(_ context.Context) ([]core.AgentSessionInfo, error) {
return nil, nil
}
// Stop shuts down the agent.
func (a *Agent) Stop() error { return nil }
// ── WorkDirSwitcher ──────────────────────────────────────────────
func (a *Agent) SetWorkDir(dir string) {
a.mu.Lock()
defer a.mu.Unlock()
a.workDir = dirView on GitHub (pinned to 4000b2338a)
Solutions
- Confirm the reasonix serve instance is running at serve_url
- Check network/firewall access from cc-connect to the serve host
- Read the wrapped error for the HTTP-level cause
Defensive patterns
Strategy: try-catch
When it happens
Trigger: Thrown at agent/reasonix/reasonix.go:84 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of chenhg5/cc-connect@4000b2338a (2026-09-06).
Data as JSON: /api/errors/bd0190dd20aaeb26.
Report an issue: GitHub.