Skip to content Search Apps Documentation Source Content File Folder Download Copy Actions State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

Community realm. Read the code first. Community realm, deployed by its author. Read the code before you interact or send coins.

errors.gno

2.29 Kb · 52 lines
 1package upgradeable
 2
 3import "errors"
 4
 5var (
 6	// ErrNoAuthority is raised when a Proxy is built, or handed, a nil
 7	// authority. There is no "nobody" authority: to end upgradeability,
 8	// Freeze it.
 9	ErrNoAuthority = errors.New("upgradeable: an authority is required")
10
11	// ErrUnauthorized is raised when the caller is not the authority.
12	ErrUnauthorized = errors.New("upgradeable: caller is not the authority")
13
14	// ErrStaleRealm is raised when the threaded realm value is not the
15	// caller's live cur -- a stashed or replayed capture.
16	ErrStaleRealm = errors.New("upgradeable: realm value is not the caller's live cur")
17
18	// ErrFrozen is raised by every mutating method once Freeze has run.
19	ErrFrozen = errors.New("upgradeable: proxy is frozen")
20
21	// ErrNoImpl is raised when the proxy is asked for an implementation it
22	// does not have yet.
23	ErrNoImpl = errors.New("upgradeable: no implementation is live")
24
25	// ErrNotNested is raised when a candidate registers from a realm that is
26	// not under the proxy realm's own path. See New and NewOpen.
27	ErrNotNested = errors.New("upgradeable: candidate realm is not nested under this one")
28
29	// ErrNotARealm is raised when a candidate registers from a user call
30	// rather than from a deployed realm, so there is no path to record.
31	ErrNotARealm = errors.New("upgradeable: only a deployed realm can register a candidate")
32
33	// ErrNilImpl is raised when the registered implementation is nil.
34	ErrNilImpl = errors.New("upgradeable: implementation is nil")
35
36	// ErrUnknownPath is raised when accepting or withdrawing a path that has
37	// no candidate registered against it.
38	ErrUnknownPath = errors.New("upgradeable: no candidate registered at that path")
39
40	// ErrNoHistory is raised by Rollback when nothing has been replaced yet.
41	ErrNoHistory = errors.New("upgradeable: no previous release to roll back to")
42
43	// ErrBadAddress is raised when an authority is built from an invalid
44	// address.
45	ErrBadAddress = errors.New("upgradeable: invalid address")
46
47	// ErrBadRealmPath is raised when an authority is built from a realm path
48	// that is blank or carries surrounding whitespace. Both are silent
49	// lockouts: a blank entry matches every user call, and a padded one
50	// matches no caller at all.
51	ErrBadRealmPath = errors.New("upgradeable: authority realm paths must be non-blank and unpadded")
52)