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

Method Validate

internal/task/validate.go:874–882  ·  view source on GitHub ↗

Validate reports whether the enqueue-run request is internally consistent.

(path string)

Source from the content-addressed store, hash-verified

872
873// Validate reports whether the enqueue-run request is internally consistent.
874func (r EnqueueRun) Validate(path string) error {
875 if strings.TrimSpace(r.TaskID) == "" {
876 return fmt.Errorf("%w: %s is required", ErrValidation, nestedPath(path, "task_id"))
877 }
878 if err := ValidateMetadataSize(r.Metadata, nestedPath(path, "metadata")); err != nil {
879 return err
880 }
881 return nil
882}
883
884// Validate reports whether the task execution request is internally consistent.
885func (r ExecutionRequest) Validate(path string) error {

Callers 2

Calls 2

ValidateMetadataSizeFunction · 0.85
nestedPathFunction · 0.70

Tested by

no test coverage detected