import { ApiClient, routes } from "@lodestar/api"; import { ChainForkConfig } from "@lodestar/config"; import { IClock } from "@lodestar/state-transition"; import { Metrics } from "../metrics.js"; import { PubkeyHex } from "../types.js"; import { LoggerVc } from "../util/index.js"; import { BlockDutiesService } from "./blockDuties.js"; import { ValidatorStore } from "./validatorStore.js"; type BlockProposalOpts = { broadcastValidation: routes.beacon.BroadcastValidation; blindedLocal: boolean; payloadLocal: boolean; }; /** * Service that sets up and handles validator block proposal duties. */ export declare class BlockProposingService { private readonly config; private readonly logger; private readonly api; private readonly clock; private readonly validatorStore; private readonly metrics; private readonly opts; private readonly dutiesService; constructor(config: ChainForkConfig, logger: LoggerVc, api: ApiClient, clock: IClock, validatorStore: ValidatorStore, dutiesService: BlockDutiesService, metrics: Metrics | null, opts: BlockProposalOpts); removeDutiesForKey(pubkey: PubkeyHex): void; /** * `BlockDutiesService` must call this fn to trigger block creation * This function may run more than once at a time, rationale in `BlockDutiesService.pollBeaconProposers` */ private notifyBlockProductionFn; /** Produce a block at the given slot for pubkey */ private createAndPublishBlock; /** * Gloas block production flow: * 1. Produce the beacon block, which commits to an execution payload bid. When self-building with * the stateless flow (`payloadLocal=false`), the response also includes the full block contents * (execution payload envelope, KZG proofs and blobs). * 2. Sign and publish the beacon block. * 3. Reveal the execution payload envelope: * - Self-build: the proposer signs and publishes the envelope * - Stateless (`payloadLocal=false`): envelope and blobs are already available from step 1, * publish `SignedExecutionPayloadEnvelopeContents` which can be sent via any beacon node * - Stateful (`payloadLocal=true`): fetch the envelope from the beacon node that produced the * block, then publish the bare `SignedExecutionPayloadEnvelope` back to it; that node * attaches the cached blobs and KZG proofs * - Builder bid: the builder reveals the envelope, so the proposer does nothing further */ private createAndPublishBlockGloas; private publishBlockWrapper; private produceBlockWrapper; } export {}; //# sourceMappingURL=block.d.ts.map