Skip to content

Commit

Permalink
fix: remove nonce manager dependency from inspector (#2266)
Browse files Browse the repository at this point in the history
  • Loading branch information
nick-bisonai authored Sep 3, 2024
1 parent c058865 commit ca39f50
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions node/pkg/chain/helper/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,9 @@ func (t *ChainHelper) GetSignedFromDelegator(tx *types.Transaction) (*types.Tran
func (t *ChainHelper) MakeDirectTx(ctx context.Context, contractAddressHex string, functionString string, args ...interface{}) (*types.Transaction, error) {
var result *types.Transaction

nonce, err := noncemanager.GetAndIncrementNonce(t.wallet)
nonce, err := utils.GetNonceFromPk(ctx, t.wallet, t.clients[0])
if err != nil {
return result, err
return nil, err
}

job := func(c utils.ClientInterface) error {
Expand Down
2 changes: 2 additions & 0 deletions node/pkg/checker/inspect/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,8 @@ func (i *Inspector) Inspect(ctx context.Context) (string, error) {
}
msg += inspectVRFResult

time.Sleep(5 * time.Second) // sleep to prevent nonce reuse read from onchain

inspectRRResult, err := i.inspectRR(ctx)
if err != nil {
log.Error().Err(err).Msg("Failed RR inspection")
Expand Down

0 comments on commit ca39f50

Please sign in to comment.