Files
consensus/types/errors.go
T
zeekay b433ac3c53 fix: resolve all build and test issues
- Fixed cmd tools to use new consensus API (NewChain instead of NewChainEngine)
- Removed deprecated Rust tests that use old API
- Fixed golangci-lint configuration
- Applied gofmt formatting to all Go files
- All Go tests passing
- All Python tests passing
- Basic Rust tests passing
2025-11-13 00:42:20 -08:00

34 lines
1.0 KiB
Go

// Copyright (C) 2019-2025, Lux Industries Inc All rights reserved.
// See the file LICENSE for licensing terms.
package types
import "errors"
// Common consensus errors
var (
// ErrBlockNotFound is returned when a block is not found
ErrBlockNotFound = errors.New("block not found")
// ErrInvalidBlock is returned when a block is invalid
ErrInvalidBlock = errors.New("invalid block")
// ErrInvalidVote is returned when a vote is invalid
ErrInvalidVote = errors.New("invalid vote")
// ErrNoQuorum is returned when there is no quorum
ErrNoQuorum = errors.New("no quorum")
// ErrAlreadyVoted is returned when a validator has already voted
ErrAlreadyVoted = errors.New("already voted")
// ErrNotValidator is returned when the node is not a validator
ErrNotValidator = errors.New("not a validator")
// ErrTimeout is returned when an operation times out
ErrTimeout = errors.New("operation timeout")
// ErrNotInitialized is returned when the engine is not initialized
ErrNotInitialized = errors.New("engine not initialized")
)