Documentation
¶
Index ¶
- Constants
- func ExitCodeFor(err error) int
- func NewAbTestCmd() *cobra.Command
- func NewAuditCmd() *cobra.Command
- func NewAutoCmd() *cobra.Command
- func NewCacheCmd() *cobra.Command
- func NewConductorRunCmd() *cobra.Command
- func NewDaemonCmd() *cobra.Command
- func NewDashboardCmd() *cobra.Command
- func NewDecomposeCmd() *cobra.Command
- func NewDockerCmd() *cobra.Command
- func NewDoctorCmd() *cobra.Command
- func NewEvalCmd() *cobra.Command
- func NewExecCmd() *cobra.Command
- func NewGenerateSpecCmd() *cobra.Command
- func NewGoCmd() *cobra.Command
- func NewHealCmd() *cobra.Command
- func NewInitCmd() *cobra.Command
- func NewMergeCmd() *cobra.Command
- func NewMonitorCmd() *cobra.Command
- func NewNewCmd() *cobra.Command
- func NewProjectsCmd() *cobra.Command
- func NewQueueCmd() *cobra.Command
- func NewReconcileCmd() *cobra.Command
- func NewRecoverCmd() *cobra.Command
- func NewReleaseCmd() *cobra.Command
- func NewResetCmd() *cobra.Command
- func NewRootCmd() *cobra.Command
- func NewSpawnCmd() *cobra.Command
- func NewStatusCmd() *cobra.Command
- func NewTokensCmd() *cobra.Command
- func NewVersionCmd() *cobra.Command
- func PrintFormattedError(w io.Writer, err error, verbose bool)
- func PrintJSONError(w io.Writer, err error)
- func TaskRecoverySuggestion(failureType string) string
- type ErrorCategory
- type OrchestraError
- type TaskFailure
Constants ¶
const ( ExitSuccess = 0 ExitGeneral = 1 ExitUsage = 2 ExitDatabase = 3 ExitGit = 4 ExitPartialFailure = 5 ExitTotalFailure = 6 ExitPreflight = 7 )
Exit codes for structured CLI error reporting.
Variables ¶
This section is empty.
Functions ¶
func ExitCodeFor ¶
ExitCodeFor extracts the exit code from an error. OrchestraError uses its typed code; other errors fall back to heuristic string matching.
func NewAutoCmd ¶
NewAutoCmd creates the auto subcommand (autonomous multi-cycle mode).
func NewCacheCmd ¶
NewCacheCmd creates the cache subcommand for plan cache management.
func NewConductorRunCmd ¶
NewConductorRunCmd creates the hidden conductor-run command. This is the detached process that actually runs the conductor lifecycle. It is spawned by `orchestra go` and not intended for direct user invocation.
func NewDaemonCmd ¶
NewDaemonCmd creates the daemon command group with all subcommands.
func NewDashboardCmd ¶
NewDashboardCmd creates the dashboard subcommand (TUI, default when no subcommand given).
func NewDecomposeCmd ¶
NewDecomposeCmd creates the decompose subcommand.
func NewDockerCmd ¶
NewDockerCmd creates the docker subcommand for runtime management.
func NewEvalCmd ¶
NewEvalCmd creates the eval subcommand with sub-commands for the evaluation framework.
func NewExecCmd ¶
NewExecCmd creates the exec subcommand (execute a multi-phase YAML spec).
func NewGenerateSpecCmd ¶
NewGenerateSpecCmd creates the generate-spec subcommand.
func NewHealCmd ¶
NewHealCmd creates the heal subcommand with sub-commands for healing diagnostics.
func NewMergeCmd ¶
NewMergeCmd creates the merge subcommand. Both batch and FIFO merge paths run post-merge content clobber detection, logging merge_content_clobber events for files that shrink by >50%.
func NewMonitorCmd ¶
NewMonitorCmd creates the monitor subcommand tree.
func NewProjectsCmd ¶
NewProjectsCmd creates the projects command group with all subcommands.
func NewQueueCmd ¶
NewQueueCmd creates the queue command group with subcommands for managing the daemon's priority queue.
func NewReconcileCmd ¶
NewReconcileCmd creates the reconcile subcommand for post-session analysis.
func NewRecoverCmd ¶
NewRecoverCmd creates the recover subcommand for orphan session recovery.
func NewReleaseCmd ¶
NewReleaseCmd creates the release command for gated version tagging.
func NewResetCmd ¶
NewResetCmd creates the reset subcommand for full cleanup.
func NewRootCmd ¶
NewRootCmd creates the root orchestra command with all subcommands registered.
func NewVersionCmd ¶
NewVersionCmd creates the version subcommand.
func PrintFormattedError ¶
PrintFormattedError writes a human-readable structured error to w. Format: summary → detail → failed tasks → next steps.
func PrintJSONError ¶
PrintJSONError writes a JSON-formatted error to w.
func TaskRecoverySuggestion ¶
TaskRecoverySuggestion maps agent failure classifier types to recovery commands.
Types ¶
type ErrorCategory ¶
type ErrorCategory string
ErrorCategory classifies errors for AI consumers.
const ( CategoryInput ErrorCategory = "input" CategoryTransient ErrorCategory = "transient" CategoryPartial ErrorCategory = "partial" CategoryFatal ErrorCategory = "fatal" )
type OrchestraError ¶
type OrchestraError struct {
ExitCode int `json:"exit_code"`
Category ErrorCategory `json:"category"`
Summary string `json:"error"`
Detail string `json:"detail,omitempty"`
Suggestions []string `json:"suggestions,omitempty"`
FailedTasks []TaskFailure `json:"failed_tasks,omitempty"`
Cause error `json:"-"`
}
OrchestraError is a structured error carrying exit code, category, recovery suggestions, and per-task failure details.
func (*OrchestraError) Error ¶
func (e *OrchestraError) Error() string
func (*OrchestraError) Unwrap ¶
func (e *OrchestraError) Unwrap() error
type TaskFailure ¶
type TaskFailure struct {
TaskID string `json:"task_id"`
Role string `json:"role,omitempty"`
Title string `json:"title,omitempty"`
FailureType string `json:"failure_type,omitempty"`
Suggestion string `json:"suggestion,omitempty"`
}
TaskFailure captures per-task failure details for structured output.
Source Files
¶
- abtest.go
- audit.go
- auto.go
- cache_cmd.go
- conductor_run_cmd.go
- daemon_cmd.go
- dashboard.go
- decompose.go
- docker_cmd.go
- doctor_cmd.go
- errors.go
- eval_cmd.go
- exec_cmd.go
- generate_spec_cmd.go
- go_cmd.go
- heal_cmd.go
- init_cmd.go
- merge.go
- monitor_cmd.go
- new_cmd.go
- projects_cmd.go
- queue_cmd.go
- reconcile_cmd.go
- recover_cmd.go
- release_cmd.go
- reset_cmd.go
- root.go
- spawn_cmd.go
- status.go
- tokens.go
- version.go
- version_check.go