Documentation
¶
Index ¶
- func ExitCode(err error) int
- func Is(err error, code Code) bool
- func IsKnownCode(code Code) bool
- func Normalize(err error) error
- func NormalizeInto(err *error)
- func Report(ctx context.Context, operation string, err error)
- func WithStage(stage string, err error) error
- type Code
- type Error
- type ExitError
- type Params
- type Payload
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsKnownCode ¶
func NormalizeInto ¶
func NormalizeInto(err *error)
Types ¶
type Code ¶
type Code string
const ( CodeInternal Code = "internal" CodeInvalidArgument Code = "invalid_argument" CodeNotAuthenticated Code = "not_authenticated" CodeAccessDenied Code = "access_denied" CodeAuthExpired Code = "authentication_expired" CodeNotInitialized Code = "not_initialized" CodeConfigNotFound Code = "config_not_found" CodeConfigProtected Code = "config_protected" // an edit would change the trust root or where secrets are stored CodeEnvironmentMissing Code = "environment_not_found" CodeEnvironmentExists Code = "environment_already_exists" CodeSecretMissing Code = "secret_not_found" CodeSecretExists Code = "secret_already_exists" CodeImportConflict Code = "import_conflict" CodeArtifactNotFound Code = "artifact_not_found" CodeConflict Code = "conflict" // Workspace security protocol. CodeNotMember Code = "not_member" // device is not (yet) in the verified Control CodeUntrusted Code = "untrusted_state" // signature, author or encoding failed verification CodeRollback Code = "rollback_detected" // storage returned something older than accepted CodeIncompatibleStorage Code = "incompatible_storage" // storage lacks a workspace control CodeSecretConflict Code = "secret_conflict" // concurrent edits changed a secret differently; a person must choose CodeControlForked Code = "control_forked" // two admins changed the members at once; an admin's next operation resolves it CodeReencryptIncomplete Code = "reencrypt_incomplete" // membership changed but secrets are not re-encrypted yet CodeTrustRootChanged Code = "trust_root_changed" // enbu.toml names a genesis other than the one this device pinned // Local device. CodeOutputUnreadable Code = "output_unreadable" // the output file is not dotenv; pulling again with replace overwrites it CodeKeyringLocked Code = "keyring_locked" // the OS keyring exists but is locked; the person must unlock it CodeUpdateUnverified Code = "update_unverified" // a downloaded update failed its signature or checksum and was not installed )
Click to show internal directories.
Click to hide internal directories.