Fantom-foundation/go-lachesis

View on GitHub

Showing 291 of 829 total issues

Avoid deeply nested control flow statements.
Open

                    if pool.discSetPeriod != nil {
                        pool.discSetPeriod <- time.Minute
                    }
Severity: Major
Found in gossip/serverpool.go - About 45 mins to fix

    Method ContractUpdatedStakeIterator.Next has 7 return statements (exceeds 4 allowed).
    Open

    func (it *ContractUpdatedStakeIterator) Next() bool {
        // If the iterator failed, stop iterating
        if it.fail != nil {
            return false
        }
    Severity: Major
    Found in gossip/sfc202/contract.go - About 45 mins to fix

      Method ContractPreparedToWithdrawStakeIterator.Next has 7 return statements (exceeds 4 allowed).
      Open

      func (it *ContractPreparedToWithdrawStakeIterator) Next() bool {
          // If the iterator failed, stop iterating
          if it.fail != nil {
              return false
          }
      Severity: Major
      Found in gossip/sfc204/contract.go - About 45 mins to fix

        Method ContractUpdatedOfflinePenaltyThresholdIterator.Next has 7 return statements (exceeds 4 allowed).
        Open

        func (it *ContractUpdatedOfflinePenaltyThresholdIterator) Next() bool {
            // If the iterator failed, stop iterating
            if it.fail != nil {
                return false
            }
        Severity: Major
        Found in gossip/sfc204/contract.go - About 45 mins to fix

          Method ContractUpdatedGasPowerAllocationRateIterator.Next has 7 return statements (exceeds 4 allowed).
          Open

          func (it *ContractUpdatedGasPowerAllocationRateIterator) Next() bool {
              // If the iterator failed, stop iterating
              if it.fail != nil {
                  return false
              }
          Severity: Major
          Found in gossip/sfc110/contract.go - About 45 mins to fix

            Method ContractCreatedDelegationIterator.Next has 7 return statements (exceeds 4 allowed).
            Open

            func (it *ContractCreatedDelegationIterator) Next() bool {
                // If the iterator failed, stop iterating
                if it.fail != nil {
                    return false
                }
            Severity: Major
            Found in gossip/sfc204/contract.go - About 45 mins to fix

              Method ContractCreatedStakeIterator.Next has 7 return statements (exceeds 4 allowed).
              Open

              func (it *ContractCreatedStakeIterator) Next() bool {
                  // If the iterator failed, stop iterating
                  if it.fail != nil {
                      return false
                  }
              Severity: Major
              Found in gossip/sfc204/contract.go - About 45 mins to fix

                Method ContractUpdatedStakerMetadataIterator.Next has 7 return statements (exceeds 4 allowed).
                Open

                func (it *ContractUpdatedStakerMetadataIterator) Next() bool {
                    // If the iterator failed, stop iterating
                    if it.fail != nil {
                        return false
                    }
                Severity: Major
                Found in gossip/sfc202/contract.go - About 45 mins to fix

                  Method ContractWithdrawnStakeIterator.Next has 7 return statements (exceeds 4 allowed).
                  Open

                  func (it *ContractWithdrawnStakeIterator) Next() bool {
                      // If the iterator failed, stop iterating
                      if it.fail != nil {
                          return false
                      }
                  Severity: Major
                  Found in gossip/sfc202/contract.go - About 45 mins to fix

                    Method ContractDeactivatedStakeIterator.Next has 7 return statements (exceeds 4 allowed).
                    Open

                    func (it *ContractDeactivatedStakeIterator) Next() bool {
                        // If the iterator failed, stop iterating
                        if it.fail != nil {
                            return false
                        }
                    Severity: Major
                    Found in gossip/sfc204/contract.go - About 45 mins to fix

                      Method ContractLockingDelegationIterator.Next has 7 return statements (exceeds 4 allowed).
                      Open

                      func (it *ContractLockingDelegationIterator) Next() bool {
                          // If the iterator failed, stop iterating
                          if it.fail != nil {
                              return false
                          }
                      Severity: Major
                      Found in gossip/sfc204/contract.go - About 45 mins to fix

                        Method ContractWithdrawnDelegationIterator.Next has 7 return statements (exceeds 4 allowed).
                        Open

                        func (it *ContractWithdrawnDelegationIterator) Next() bool {
                            // If the iterator failed, stop iterating
                            if it.fail != nil {
                                return false
                            }
                        Severity: Major
                        Found in gossip/sfc204/contract.go - About 45 mins to fix

                          Method ContractIncreasedDelegationIterator.Next has 7 return statements (exceeds 4 allowed).
                          Open

                          func (it *ContractIncreasedDelegationIterator) Next() bool {
                              // If the iterator failed, stop iterating
                              if it.fail != nil {
                                  return false
                              }
                          Severity: Major
                          Found in gossip/sfc204/contract.go - About 45 mins to fix

                            Method ContractLockingDelegationIterator.Next has 7 return statements (exceeds 4 allowed).
                            Open

                            func (it *ContractLockingDelegationIterator) Next() bool {
                                // If the iterator failed, stop iterating
                                if it.fail != nil {
                                    return false
                                }
                            Severity: Major
                            Found in gossip/sfc202/contract.go - About 45 mins to fix

                              Method ContractPartialWithdrawnByRequestIterator.Next has 7 return statements (exceeds 4 allowed).
                              Open

                              func (it *ContractPartialWithdrawnByRequestIterator) Next() bool {
                                  // If the iterator failed, stop iterating
                                  if it.fail != nil {
                                      return false
                                  }
                              Severity: Major
                              Found in gossip/sfc204/contract.go - About 45 mins to fix

                                Method ContractLockingStakeIterator.Next has 7 return statements (exceeds 4 allowed).
                                Open

                                func (it *ContractLockingStakeIterator) Next() bool {
                                    // If the iterator failed, stop iterating
                                    if it.fail != nil {
                                        return false
                                    }
                                Severity: Major
                                Found in gossip/sfc202/contract.go - About 45 mins to fix

                                  Method ContractNetworkUpgradeActivatedIterator.Next has 7 return statements (exceeds 4 allowed).
                                  Open

                                  func (it *ContractNetworkUpgradeActivatedIterator) Next() bool {
                                      // If the iterator failed, stop iterating
                                      if it.fail != nil {
                                          return false
                                      }
                                  Severity: Major
                                  Found in gossip/sfc202/contract.go - About 45 mins to fix

                                    Method ContractUpdatedMinGasPriceIterator.Next has 7 return statements (exceeds 4 allowed).
                                    Open

                                    func (it *ContractUpdatedMinGasPriceIterator) Next() bool {
                                        // If the iterator failed, stop iterating
                                        if it.fail != nil {
                                            return false
                                        }
                                    Severity: Major
                                    Found in gossip/sfc202/contract.go - About 45 mins to fix

                                      Method ContractUpdatedDelegationIterator.Next has 7 return statements (exceeds 4 allowed).
                                      Open

                                      func (it *ContractUpdatedDelegationIterator) Next() bool {
                                          // If the iterator failed, stop iterating
                                          if it.fail != nil {
                                              return false
                                          }
                                      Severity: Major
                                      Found in gossip/sfc204/contract.go - About 45 mins to fix

                                        Method ContractUpdatedMinGasPriceIterator.Next has 7 return statements (exceeds 4 allowed).
                                        Open

                                        func (it *ContractUpdatedMinGasPriceIterator) Next() bool {
                                            // If the iterator failed, stop iterating
                                            if it.fail != nil {
                                                return false
                                            }
                                        Severity: Major
                                        Found in gossip/sfc204/contract.go - About 45 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language