Co-authored-by: cool-developer <51834436+cool-develope@users.noreply.github.com> Co-authored-by: yihuang <huang@crypto.com>
39 lines
1.5 KiB
Go
39 lines
1.5 KiB
Go
package store
|
|
|
|
import (
|
|
"cosmossdk.io/errors"
|
|
)
|
|
|
|
// StoreCodespace defines the store package's unique error code space.
|
|
const StoreCodespace = "store"
|
|
|
|
var (
|
|
// ErrInvalidProof is returned when a proof is invalid
|
|
ErrInvalidProof = errors.Register(StoreCodespace, 2, "invalid proof")
|
|
|
|
// ErrTxDecode is returned if we cannot parse a transaction
|
|
ErrTxDecode = errors.Register(StoreCodespace, 3, "tx parse error")
|
|
|
|
// ErrUnknownRequest to doc
|
|
ErrUnknownRequest = errors.Register(StoreCodespace, 4, "unknown request")
|
|
|
|
// ErrLogic defines an internal logic error, e.g. an invariant or assertion
|
|
// that is violated. It is a programmer error, not a user-facing error.
|
|
ErrLogic = errors.Register(StoreCodespace, 5, "internal logic error")
|
|
|
|
// ErrConflict defines a conflict error, e.g. when two goroutines try to access
|
|
// the same resource and one of them fails.
|
|
ErrConflict = errors.Register(StoreCodespace, 6, "conflict")
|
|
|
|
// ErrInvalidRequest defines an ABCI typed error where the request contains
|
|
// invalid data.
|
|
ErrInvalidRequest = errors.Register(StoreCodespace, 7, "invalid request")
|
|
|
|
ErrClosed = errors.Register(StoreCodespace, 8, "closed")
|
|
ErrRecordNotFound = errors.Register(StoreCodespace, 9, "record not found")
|
|
ErrUnknownStoreKey = errors.Register(StoreCodespace, 10, "unknown store key")
|
|
ErrInvalidVersion = errors.Register(StoreCodespace, 11, "invalid version")
|
|
ErrKeyEmpty = errors.Register(StoreCodespace, 12, "key empty")
|
|
ErrStartAfterEnd = errors.Register(StoreCodespace, 13, "start key after end key")
|
|
)
|