mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-22 03:30:35 +00:00
0eff83cb9d
* Use a cache of one entry to build attestation * Gazelle * Enforce on RPC side * Rm unused var * Potuz feedback, dont use pointer * Fix tests * Init fetcher * Add in-progress * Add back missing lock * Potuz feedback * Update beacon-chain/rpc/prysm/v1alpha1/validator/attester_test.go Co-authored-by: Potuz <potuz@prysmaticlabs.com> --------- Co-authored-by: Potuz <potuz@prysmaticlabs.com>
23 lines
1.1 KiB
Go
23 lines
1.1 KiB
Go
package cache
|
|
|
|
import "github.com/pkg/errors"
|
|
|
|
var (
|
|
// ErrNilValueProvided for when we try to put a nil value in a cache.
|
|
ErrNilValueProvided = errors.New("nil value provided on Put()")
|
|
// ErrIncorrectType for when the state is of the incorrect type.
|
|
ErrIncorrectType = errors.New("incorrect state type provided")
|
|
// ErrNotFound for cache fetches that return a nil value.
|
|
ErrNotFound = errors.New("not found in cache")
|
|
// ErrNonExistingSyncCommitteeKey when sync committee key (root) does not exist in cache.
|
|
ErrNonExistingSyncCommitteeKey = errors.New("does not exist sync committee key")
|
|
errNotSyncCommitteeIndexPosition = errors.New("not syncCommitteeIndexPosition struct")
|
|
// ErrNotFoundRegistration when validator registration does not exist in cache.
|
|
ErrNotFoundRegistration = errors.Wrap(ErrNotFound, "no validator registered")
|
|
|
|
// ErrAlreadyInProgress appears when attempting to mark a cache as in progress while it is
|
|
// already in progress. The client should handle this error and wait for the in progress
|
|
// data to resolve via Get.
|
|
ErrAlreadyInProgress = errors.New("already in progress")
|
|
)
|