Mintbase / arak

General Purpose Ethereum Event Indexer
GNU General Public License v3.0
1 stars 1 forks source link

Warnings on "Bad" Contract #8

Open bh2smith opened 11 months ago

bh2smith commented 11 months ago

We got a few WARNINGS when indexing the approval_for_all event:

[[event]]
name = "approval_for_all"
start = 0
contract = "*"
signature = "event ApprovalForAll(address indexed owner, address indexed operator, bool approved)"

This is due to a couple of contracts (here is one for example that implement the event differently (approved is indexed).

event ApprovalForAll(address indexed _owner, address indexed _operator, bool indexed _approved);

There are only a handful of contracts doing this (2 that I have seen so far), and we may have to create another table for them (say indexed_approval_for_all). We should also try to figure out how to skip the warning.

Example Digest ``` 2023-09-23T20:20:59.020545Z WARN arak::indexer: failed to decode log err=unexpected end of buffer while decoding log=Log { removed: false, log_index: 4, transaction_index: 5, transaction_hash: Digest(0xe251d1a9973af6fd015b753887d835a667146e6c78793073c1ac380ba32cc575), block_hash: Digest(0x8ade0d9f16dbcc24d6dee66f1062a459cf2dbdbeb756a23ac2107b72637fe5be), block_number: 6729704, address: Address(0x8853B05833029e3Cf8d3Cbb592f9784FA43d2a79), data: 0x, topics: [Digest(0x17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31), Digest(0x00000000000000000000000080efc17ccdc8fe6a625cc4ed1fdaf71fd81a2c99), Digest(0x00000000000000000000000080f7697f0052aaef8a3ff5dbdb39cf623e0baa49), Digest(0x0000000000000000000000000000000000000000000000000000000000000001)] } ```