errors

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 1, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrGoctlNotFound      = errors.New("goctl not found")
	ErrGoctlExecution     = errors.New("goctl execution failed")
	ErrInvalidServiceName = errors.New("invalid service name")
	ErrInvalidPort        = errors.New("invalid port")
	ErrInvalidPath        = errors.New("invalid path")
	ErrValidationFailed   = errors.New("validation failed")
	ErrProjectStructure   = errors.New("invalid project structure")
	ErrModuleInit         = errors.New("module initialization failed")
	ErrImportFix          = errors.New("import path fix failed")
	ErrConfigUpdate       = errors.New("config update failed")
)

Functions

func IsExecutionError

func IsExecutionError(err error) bool

func IsNotFound

func IsNotFound(err error) bool

func IsValidationError

func IsValidationError(err error) bool

Types

type ExecutionError

type ExecutionError struct {
	Command  string
	Args     []string
	Stdout   string
	Stderr   string
	ExitCode int
	Err      error
}

ExecutionError represents a goctl execution failure

func NewExecutionError

func NewExecutionError(command string, args []string, stdout, stderr string, exitCode int, err error) *ExecutionError

func (*ExecutionError) Error

func (e *ExecutionError) Error() string

func (*ExecutionError) Unwrap

func (e *ExecutionError) Unwrap() error

type PathError

type PathError struct {
	Path    string
	Op      string
	Message string
	Err     error
}

PathError represents a file/directory path error

func NewPathError

func NewPathError(path, op, message string, err error) *PathError

func (*PathError) Error

func (e *PathError) Error() string

func (*PathError) Unwrap

func (e *PathError) Unwrap() error

type ValidationError

type ValidationError struct {
	Field   string
	Value   string
	Message string
	Err     error
}

ValidationError represents a validation failure

func NewValidationError

func NewValidationError(field, value, message string, err error) *ValidationError

func (*ValidationError) Error

func (e *ValidationError) Error() string

func (*ValidationError) Unwrap

func (e *ValidationError) Unwrap() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL