Discover Packages
github.com/andrewkydev/astraengine/v2
core
errors
package
Version:
v2.0.4
Opens a new window with list of versions in this module.
Published: Aug 26, 2026
License: GPL-3.0
Opens a new window with license information.
Imports: 3
Opens a new window with list of imports.
Imported by: ? modules, 0 packages
The first number is the count of modules that contain a package that imports this one.
The module count is a better indicator of popularity than the package count.
A module with 100 importing packages is counted only once instead of 100 times,
reflecting the fact that the choice to use the package was likely made only once,
not 100 times.
A '?' means that the value hasn't been computed yet.
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package errors defines machine-readable AstraEngine errors.
IsCode reports whether err has code.
IsRetryable reports whether a typed error can be retried.
PublicMessage returns a safe client-facing message without the wrapped cause.
Code is a stable, machine-readable error category.
const (
CodeInternal Code = "internal"
CodeInvalidArgument Code = "invalid_argument"
CodeNotFound Code = "not_found"
CodeUnauthorized Code = "unauthorized"
CodeForbidden Code = "forbidden"
CodeConflict Code = "conflict"
CodeUnavailable Code = "unavailable"
CodeRateLimited Code = "rate_limited"
CodeUnsupported Code = "unsupported"
CodeCanceled Code = "canceled"
CodeDeadline Code = "deadline_exceeded"
)
CodeOf returns the nearest AstraEngine code, including context cancellation.
Error adds stable metadata to an underlying error.
New creates an error with a safe public message.
Wrap annotates err with a code and operation while preserving its cause.
Unwrap returns the underlying cause for errors.Is and errors.As.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.