MCPcopy Create free account
hub / github.com/compozy/agh / NewTaskValidationError

Function NewTaskValidationError

internal/api/core/errors.go:342–347  ·  view source on GitHub ↗

NewTaskValidationError wraps a task validation failure with the shared sentinel.

(err error)

Source from the content-addressed store, hash-verified

340
341// NewTaskValidationError wraps a task validation failure with the shared sentinel.
342func NewTaskValidationError(err error) error {
343 if err == nil {
344 return nil
345 }
346 return fmt.Errorf("%w: %w", taskpkg.ErrValidation, err)
347}
348
349// StatusForTaskError maps task-domain, workspace, and session failures to transport statuses.
350func StatusForTaskError(err error) int {

Callers 15

TestStatusForTaskErrorFunction · 0.92
ParseTaskListQueryFunction · 0.85
ParseTaskRunListQueryFunction · 0.85
ParseTaskTimelineQueryFunction · 0.85
ParseTaskStreamQueryFunction · 0.85
ParseTaskInboxQueryFunction · 0.85

Calls

no outgoing calls

Tested by 2

TestStatusForTaskErrorFunction · 0.74
TestTaskErrorHelpersFunction · 0.68