From ceb9bab651a921f7691de050602df45d23b6aee4 Mon Sep 17 00:00:00 2001 From: Nikita Pozdniakov Date: Fri, 22 Sep 2023 14:29:43 +0300 Subject: [PATCH 1/2] Handle ':error.types/0 is undefined' error --- apps/explorer/lib/explorer/chain/transaction.ex | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/apps/explorer/lib/explorer/chain/transaction.ex b/apps/explorer/lib/explorer/chain/transaction.ex index c40d87769f..82967c0c06 100644 --- a/apps/explorer/lib/explorer/chain/transaction.ex +++ b/apps/explorer/lib/explorer/chain/transaction.ex @@ -756,12 +756,12 @@ defmodule Explorer.Chain.Transaction do end defp find_and_decode(abi, data, hash) do - result = - abi - |> ABI.parse_specification() - |> ABI.find_and_decode(data) - - {:ok, result} + with {%FunctionSelector{}, _mapping} = result <- + abi + |> ABI.parse_specification() + |> ABI.find_and_decode(data) do + {:ok, result} + end rescue e -> Logger.warn(fn -> From 3d483fcdab61b01bfce8b1ef7a81ab0ea1d7647b Mon Sep 17 00:00:00 2001 From: Nikita Pozdniakov Date: Fri, 22 Sep 2023 14:33:11 +0300 Subject: [PATCH 2/2] Changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 890e43e8a6..12b41373fb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ ### Fixes +- [#8515](https://github.com/blockscout/blockscout/pull/8515) - Fix `:error.types/0 is undefined` warning - [#7959](https://github.com/blockscout/blockscout/pull/7959) - Fix empty batch transfers handling - [#8513](https://github.com/blockscout/blockscout/pull/8513) - Don't override transaction status