Skip to content
This repository has been archived by the owner on May 11, 2024. It is now read-only.

Commit

Permalink
fix comments
Browse files Browse the repository at this point in the history
  • Loading branch information
mask-pp committed Jan 18, 2024
1 parent 5a07ca5 commit 7327658
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 12 deletions.
10 changes: 2 additions & 8 deletions proposer/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ type Config struct {
LocalAddressesOnly bool
ProposeEmptyBlocksInterval *time.Duration
MaxProposedTxListsPerEpoch uint64
ProposeBlockTxGasLimit *uint64
ProposeBlockTxGasLimit uint64
ProposeBlockTxReplacementMultiplier uint64
WaitReceiptTimeout time.Duration
ProposeBlockTxGasTipCap *big.Int
Expand Down Expand Up @@ -74,12 +74,6 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) {
}
}

var proposeBlockTxGasLimit *uint64
if c.IsSet(flags.ProposeBlockTxGasLimit.Name) {
gasLimit := c.Uint64(flags.ProposeBlockTxGasLimit.Name)
proposeBlockTxGasLimit = &gasLimit
}

proposeBlockTxReplacementMultiplier := c.Uint64(flags.ProposeBlockTxReplacementMultiplier.Name)
if proposeBlockTxReplacementMultiplier == 0 {
return nil, fmt.Errorf(
Expand Down Expand Up @@ -120,7 +114,7 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) {
LocalAddressesOnly: c.Bool(flags.TxPoolLocalsOnly.Name),
ProposeEmptyBlocksInterval: proposeEmptyBlocksInterval,
MaxProposedTxListsPerEpoch: c.Uint64(flags.MaxProposedTxListsPerEpoch.Name),
ProposeBlockTxGasLimit: proposeBlockTxGasLimit,
ProposeBlockTxGasLimit: c.Uint64(flags.ProposeBlockTxGasLimit.Name),
ProposeBlockTxReplacementMultiplier: proposeBlockTxReplacementMultiplier,
WaitReceiptTimeout: c.Duration(flags.WaitReceiptTimeout.Name),
ProposeBlockTxGasTipCap: proposeBlockTxGasTipCap,
Expand Down
4 changes: 1 addition & 3 deletions proposer/proposer.go
Original file line number Diff line number Diff line change
Expand Up @@ -325,9 +325,7 @@ func (p *Proposer) sendProposeBlockTx(
if nonce != nil {
opts.Nonce = new(big.Int).SetUint64(*nonce)
}
if p.ProposeBlockTxGasLimit != nil {
opts.GasLimit = *p.ProposeBlockTxGasLimit
}
opts.GasLimit = p.ProposeBlockTxGasLimit
if isReplacement {
if opts, err = rpc.IncreaseGasTipCap(
ctx,
Expand Down
2 changes: 1 addition & 1 deletion prover/prover.go
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ func InitFromConfig(ctx context.Context, p *Prover, cfg *Config) (err error) {
GuardianProverAddress: cfg.GuardianProverAddress,
RetryInterval: cfg.BackOffRetryInterval,
Timeout: cfg.RPCTimeout,
BackOffMaxRetries: p.cfg.BackOffMaxRetrys,
BackOffMaxRetries: cfg.BackOffMaxRetrys,
}); err != nil {
return err
}
Expand Down

0 comments on commit 7327658

Please sign in to comment.