@lodestar/beacon-node
Version:
A Typescript implementation of the beacon chain
30 lines • 1.31 kB
TypeScript
import { VoluntaryExitValidity } from "@lodestar/state-transition";
import { GossipActionError } from "./gossipValidation.js";
export declare enum VoluntaryExitErrorCode {
ALREADY_EXISTS = "VOLUNTARY_EXIT_ERROR_ALREADY_EXISTS",
INACTIVE = "VOLUNTARY_EXIT_ERROR_INACTIVE",
ALREADY_EXITED = "VOLUNTARY_EXIT_ERROR_ALREADY_EXITED",
EARLY_EPOCH = "VOLUNTARY_EXIT_ERROR_EARLY_EPOCH",
SHORT_TIME_ACTIVE = "VOLUNTARY_EXIT_ERROR_SHORT_TIME_ACTIVE",
PENDING_WITHDRAWALS = "VOLUNTARY_EXIT_ERROR_PENDING_WITHDRAWALS",
INVALID_SIGNATURE = "VOLUNTARY_EXIT_ERROR_INVALID_SIGNATURE"
}
export type VoluntaryExitErrorType = {
code: VoluntaryExitErrorCode.ALREADY_EXISTS;
} | {
code: VoluntaryExitErrorCode.INACTIVE;
} | {
code: VoluntaryExitErrorCode.ALREADY_EXITED;
} | {
code: VoluntaryExitErrorCode.EARLY_EPOCH;
} | {
code: VoluntaryExitErrorCode.SHORT_TIME_ACTIVE;
} | {
code: VoluntaryExitErrorCode.PENDING_WITHDRAWALS;
} | {
code: VoluntaryExitErrorCode.INVALID_SIGNATURE;
};
export declare class VoluntaryExitError extends GossipActionError<VoluntaryExitErrorType> {
}
export declare function voluntaryExitValidityToErrorCode(validity: Exclude<VoluntaryExitValidity, VoluntaryExitValidity.valid>): VoluntaryExitErrorCode;
//# sourceMappingURL=voluntaryExitError.d.ts.map