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

Commit

Permalink
remove redundant flag
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerLamTd committed Nov 16, 2023
1 parent 0ee8259 commit 80a297c
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 13 deletions.
7 changes: 0 additions & 7 deletions cmd/flags/prover.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,6 @@ var (
Usage: "If set, prover will start proving blocks from the block with this ID",
Category: proverCategory,
}
MaxConcurrentProvingJobs = &cli.UintFlag{
Name: "prover.maxConcurrentJobs",
Usage: "Limits the number of concurrent proving blocks jobs",
Value: 1,
Category: proverCategory,
}
Graffiti = &cli.StringFlag{
Name: "prover.graffiti",
Usage: "When string is passed, adds additional graffiti info to proof evidence",
Expand Down Expand Up @@ -170,7 +164,6 @@ var ProverFlags = MergeFlags(CommonFlags, []cli.Flag{
MinPseZkevmTierFee,
MinSgxAndPseZkevmTierFee,
StartingBlockID,
MaxConcurrentProvingJobs,
Dummy,
GuardianProver,
GuardianProverPrivateKey,
Expand Down
2 changes: 0 additions & 2 deletions prover/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ type Config struct {
ZKEvmRpcdEndpoint string
ZkEvmRpcdParamsPath string
StartingBlockID *big.Int
MaxConcurrentProvingJobs uint
Dummy bool
GuardianProverAddress common.Address
GuardianProverPrivateKey *ecdsa.PrivateKey
Expand Down Expand Up @@ -114,7 +113,6 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) {
ZKEvmRpcdEndpoint: c.String(flags.ZkEvmRpcdEndpoint.Name),
ZkEvmRpcdParamsPath: c.String(flags.ZkEvmRpcdParamsPath.Name),
StartingBlockID: startingBlockID,
MaxConcurrentProvingJobs: c.Uint(flags.MaxConcurrentProvingJobs.Name),
Dummy: c.Bool(flags.Dummy.Name),
GuardianProverAddress: common.HexToAddress(c.String(flags.GuardianProver.Name)),
GuardianProverPrivateKey: guardianProverPrivKey,
Expand Down
4 changes: 2 additions & 2 deletions prover/prover.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,8 @@ func InitFromConfig(ctx context.Context, p *Prover, cfg *Config) (err error) {
}

// Concurrency guards
p.proposeConcurrencyGuard = make(chan struct{}, cfg.MaxConcurrentProvingJobs)
p.submitProofConcurrencyGuard = make(chan struct{}, cfg.MaxConcurrentProvingJobs)
p.proposeConcurrencyGuard = make(chan struct{}, cfg.Capacity)
p.submitProofConcurrencyGuard = make(chan struct{}, cfg.Capacity)

// Protocol proof tiers
if p.tiers, err = p.rpc.GetTiers(ctx); err != nil {
Expand Down
2 changes: 0 additions & 2 deletions prover/prover_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ func (s *ProverTestSuite) SetupTest() {
L1ProverPrivKey: l1ProverPrivKey,
GuardianProverPrivateKey: l1ProverPrivKey,
Dummy: true,
MaxConcurrentProvingJobs: 1,
ProveUnassignedBlocks: true,
Capacity: 1024,
MinOptimisticTierFee: common.Big1,
Expand Down Expand Up @@ -140,7 +139,6 @@ func (s *ProverTestSuite) TestInitError() {
L1ProverPrivKey: l1ProverPrivKey,
GuardianProverPrivateKey: l1ProverPrivKey,
Dummy: true,
MaxConcurrentProvingJobs: 1,
ProveUnassignedBlocks: true,
ProveBlockTxReplacementMultiplier: 2,
})), "dial tcp:")
Expand Down

0 comments on commit 80a297c

Please sign in to comment.