Preserve version one error record scopes

This commit is contained in:
2026-11-17 03:54:41 +00:00
parent 0c2a2164ec
commit c6be2ec20d
7 changed files with 71 additions and 47 deletions

View File

@@ -49,25 +49,31 @@ type Failure struct {
}
type ErrorRecord struct {
Scope string `yaml:"scope"`
StageIndex *int `yaml:"stage_index,omitempty"`
StageID *string `yaml:"stage_id,omitempty"`
ModuleKey string `yaml:"module_key,omitempty"`
ModuleInstance string `yaml:"module_instance,omitempty"`
ChunkIndex *int `yaml:"chunk_index,omitempty"`
StartSegmentID *int `yaml:"start_segment_id,omitempty"`
EndSegmentID *int `yaml:"end_segment_id,omitempty"`
CorrectionsApplied *int `yaml:"corrections_applied,omitempty"`
Failures []Failure `yaml:"failures,omitempty"`
Phase string `yaml:"phase,omitempty"`
Reason string `yaml:"reason,omitempty"`
Message string `yaml:"message,omitempty"`
Operation string `yaml:"operation,omitempty"`
Validator string `yaml:"validator,omitempty"`
BatchIndex *int `yaml:"batch_index,omitempty"`
ProposalIndex *int `yaml:"proposal_index,omitempty"`
RepairAttempt *int `yaml:"repair_attempt,omitempty"`
OutputPath string `yaml:"output_path,omitempty"`
Scope string `yaml:"scope"`
FailureDetails `yaml:",inline"`
StartSegmentID *int `yaml:"start_segment_id,omitempty"`
EndSegmentID *int `yaml:"end_segment_id,omitempty"`
CorrectionsApplied *int `yaml:"corrections_applied,omitempty"`
Failures []Failure `yaml:"failures,omitempty"`
OutputPath string `yaml:"output_path,omitempty"`
Interruptions []FailureDetails `yaml:"interruptions,omitempty"`
}
// FailureDetails carries a run failure's classification and available origin.
type FailureDetails struct {
StageIndex *int `yaml:"stage_index,omitempty"`
StageID *string `yaml:"stage_id,omitempty"`
ModuleKey string `yaml:"module_key,omitempty"`
ModuleInstance string `yaml:"module_instance,omitempty"`
ChunkIndex *int `yaml:"chunk_index,omitempty"`
Phase string `yaml:"phase,omitempty"`
Reason string `yaml:"reason,omitempty"`
Message string `yaml:"message,omitempty"`
Operation string `yaml:"operation,omitempty"`
Validator string `yaml:"validator,omitempty"`
BatchIndex *int `yaml:"batch_index,omitempty"`
ProposalIndex *int `yaml:"proposal_index,omitempty"`
RepairAttempt *int `yaml:"repair_attempt,omitempty"`
}
type FilteredProposal struct {