Skip to content

Commit

Permalink
feat: always use produceBlockV3 post deneb
Browse files Browse the repository at this point in the history
  • Loading branch information
g11tech committed Jan 8, 2024
1 parent fce884d commit 75ef3ae
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/cli/src/cmds/validator/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ export const validatorOptions: CliCommandOptions<IValidatorCliArgs> = {

useProduceBlockV3: {
type: "boolean",
description: "Enable/disable usage of produceBlockV3 that might not be supported by all beacon clients yet",
description: "Enable/disable usage of produceBlockV3 pre deneb that might not be supported by all beacon clients yet",
defaultDescription: `${defaultOptions.useProduceBlockV3}`,
},

Expand Down
5 changes: 3 additions & 2 deletions packages/validator/src/services/block.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,19 +125,20 @@ export class BlockProposingService {
this.validatorStore.getBuilderSelectionParams(pubkeyHex);
const feeRecipient = this.validatorStore.getFeeRecipient(pubkeyHex);
const blindedLocal = this.opts.blindedLocal;
const useProduceBlockV3 = this.config.getForkSeq(slot) >= ForkSeq.deneb || this.opts.useProduceBlockV3;

this.logger.debug("Producing block", {
...debugLogCtx,
builderSelection,
builderBoostFactor,
feeRecipient,
strictFeeRecipientCheck,
useProduceBlockV3: this.opts.useProduceBlockV3,
useProduceBlockV3,
blindedLocal,
});
this.metrics?.proposerStepCallProduceBlock.observe(this.clock.secFromSlot(slot));

const produceBlockFn = this.opts.useProduceBlockV3 ? this.produceBlockWrapper : this.produceBlockV2Wrapper;
const produceBlockFn = useProduceBlockV3 ? this.produceBlockWrapper : this.produceBlockV2Wrapper;
const produceOpts = {
feeRecipient,
strictFeeRecipientCheck,
Expand Down

0 comments on commit 75ef3ae

Please sign in to comment.