From 16dd210dc9193ba9ce8a0664d1fc2a54a65262f4 Mon Sep 17 00:00:00 2001 From: Jeffery Walsh Date: Tue, 20 Jun 2023 07:31:36 -0700 Subject: [PATCH] cnacel waiting for receipts --- packages/relayer/message/process_message.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/relayer/message/process_message.go b/packages/relayer/message/process_message.go index f2c5d01b5cb..84671a88930 100644 --- a/packages/relayer/message/process_message.go +++ b/packages/relayer/message/process_message.go @@ -6,6 +6,7 @@ import ( "fmt" "math/big" "strings" + "time" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi/bind" @@ -99,6 +100,10 @@ func (p *Processor) ProcessMessage( relayer.EventsProcessed.Inc() + ctx, cancel := context.WithTimeout(ctx, 3*time.Minute) + + defer cancel() + receipt, err := relayer.WaitReceipt(ctx, p.destEthClient, tx.Hash()) if err != nil { return errors.Wrap(err, "relayer.WaitReceipt")