From 6baa4aef342d550178bea8330cb62674ee4e0060 Mon Sep 17 00:00:00 2001 From: lumtis Date: Wed, 20 Nov 2024 10:14:49 +0100 Subject: [PATCH] comments --- cmd/zetae2e/run.go | 2 +- zetaclient/chains/evm/observer/inbound.go | 5 ++++- .../evm/observer/{v2_tracker.go => v2_inbound_tracker.go} | 0 3 files changed, 5 insertions(+), 2 deletions(-) rename zetaclient/chains/evm/observer/{v2_tracker.go => v2_inbound_tracker.go} (100%) diff --git a/cmd/zetae2e/run.go b/cmd/zetae2e/run.go index fe28c4e0ce..91116f234c 100644 --- a/cmd/zetae2e/run.go +++ b/cmd/zetae2e/run.go @@ -124,7 +124,7 @@ func runE2ETest(cmd *cobra.Command, args []string) error { conf.ZetaChainID, ) if err != nil { - return nil + return err } runnerOpts = append(runnerOpts, runner.WithZetaTxServer(zetaTxServer)) } diff --git a/zetaclient/chains/evm/observer/inbound.go b/zetaclient/chains/evm/observer/inbound.go index d5ecdac7b1..d7632ac192 100644 --- a/zetaclient/chains/evm/observer/inbound.go +++ b/zetaclient/chains/evm/observer/inbound.go @@ -147,7 +147,10 @@ func (ob *Observer) ProcessInboundTrackers(ctx context.Context) error { // if the transaction is sent to the gateway, this is a v2 inbound gatewayAddr, gateway, err := ob.GetGatewayContract() - if err == nil && ethcommon.HexToAddress(tx.To) == gatewayAddr { + if err != nil { + ob.Logger().Inbound.Debug().Err(err).Msg("error getting gateway contract for processing inbound tracker") + } + if err == nil && tx != nil && ethcommon.HexToAddress(tx.To) == gatewayAddr { if err := ob.ProcessInboundTrackerV2(ctx, gateway, tx, receipt); err != nil { return err } diff --git a/zetaclient/chains/evm/observer/v2_tracker.go b/zetaclient/chains/evm/observer/v2_inbound_tracker.go similarity index 100% rename from zetaclient/chains/evm/observer/v2_tracker.go rename to zetaclient/chains/evm/observer/v2_inbound_tracker.go