Documentation
¶
Overview ¶
Package validate provides JSONL validation against the bd import schema. It checks each line of a JSONL file for required fields, valid types, and correct formats, producing detailed error messages with fix suggestions.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ValidStatuses = []string{"open", "closed"}
ValidStatuses are the allowed values for the "status" field in a bead record.
View Source
var ValidTypes = []string{"bug", "task", "chore", "epic", "feature"}
ValidTypes are the allowed values for the "type" field in a bead record.
Functions ¶
This section is empty.
Types ¶
type Result ¶
type Result struct {
TotalLines int
Errors []ValidationError
}
Result contains the outcome of validating a JSONL file.
type ValidationError ¶
type ValidationError struct {
Line int // 1-based line number
Field string // field name (empty if line-level error)
Message string // what's wrong
Suggestion string // how to fix it
}
ValidationError represents a single validation issue on a specific line.
func (*ValidationError) Error ¶
func (e *ValidationError) Error() string
Error implements the error interface.
Click to show internal directories.
Click to hide internal directories.