errors

package
v0.2.7 Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const RootCodeSpace = "relayer"

Variables

View Source
var (
	ErrInternal            = Register(RootCodeSpace, 1, "internal")
	ErrChainConn           = Register(RootCodeSpace, 2, "connection chain failed")
	ErrGetLightClientState = Register(RootCodeSpace, 3, "failed to get light client state")
	ErrGetBlockHeader      = Register(RootCodeSpace, 4, "failed to get block header")
	ErrUpdateClient        = Register(RootCodeSpace, 5, "failed to update client")
	ErrGetPackets          = Register(RootCodeSpace, 6, "failed to get packets")
	ErrGetCommitmentPacket = Register(RootCodeSpace, 7, "failed to get commitment packet")
	ErrGetAckPacket        = Register(RootCodeSpace, 8, "failed to get ack packet")
	ErrGetReceiptPacket    = Register(RootCodeSpace, 9, "failed to get receipt packet")
	ErrGetProof            = Register(RootCodeSpace, 10, "failed to get proof")
	ErrGetLatestHeight     = Register(RootCodeSpace, 11, "failed to get latest height")
	ErrRecvPacket          = Register(RootCodeSpace, 12, "failed to recv packet")
	ErrNotProduced         = Register(RootCodeSpace, 13, "failed to not produced")
	ErrDelayTime           = Register(RootCodeSpace, 14, "failed to get delay time")
	ErrDelayHeight         = Register(RootCodeSpace, 15, "failed to get delay height")
	ErrCurBlockTime        = Register(RootCodeSpace, 16, "failed to get current block time")
	ErrUnknownMsg          = Register(RootCodeSpace, 17, "failed to unknown msg type")
)

Functions

This section is empty.

Types

type Error

type Error struct {
	// contains filtered or unexported fields
}

func New

func New(codeSpace string, code uint32, desc string) *Error

func Register

func Register(codespace string, code uint32, description string) *Error

func (Error) Code

func (e Error) Code() uint32

func (Error) CodeSpace

func (e Error) CodeSpace() string

func (Error) Error

func (e Error) Error() string

type IError

type IError interface {
	error
	Code() uint32
	CodeSpace() string
}

Jump to

Keyboard shortcuts

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