Browse Source

node/watcher: filter recv_packet events (#2883)

Nikhil Suri 2 years ago
parent
commit
b8b425263b
1 changed files with 5 additions and 0 deletions
  1. 5 0
      node/pkg/watchers/cosmwasm/watcher.go

+ 5 - 0
node/pkg/watchers/cosmwasm/watcher.go

@@ -342,6 +342,11 @@ func EventsToMessagePublications(contract string, txHash string, events []gjson.
 			continue
 			continue
 		}
 		}
 		eventType := gjson.Get(event.String(), "type")
 		eventType := gjson.Get(event.String(), "type")
+		if eventType.String() == "recv_packet" {
+			logger.Warn("processing ibc-related events is disabled", zap.String("network", networkName), zap.String("tx_hash", txHash), zap.String("event", event.String()))
+			return []*common.MessagePublication{}
+		}
+
 		if eventType.String() != "wasm" {
 		if eventType.String() != "wasm" {
 			continue
 			continue
 		}
 		}