streamingfast / firehose

An app library to share dfuse Firehose implementation across all supported chain
Apache License 2.0
36 stars 9 forks source link

investigate missing polygon transactions #25

Closed sduchesneau closed 1 year ago

sduchesneau commented 1 year ago

fireeth tools firehose-client polygon.streamingfast.io:443 45526256 45526256 |jq . > polygon45526256.json grep -i 7ed01e15e7282696cf3dc73268ef2c84a46203bb54fed6f0451d4a0eb5e5cbd5 polygon45526256.json ## this transaction should be there: https://polygonscan.com/tx/0x7ed01e15e7282696cf3dc73268ef2c84a46203bb54fed6f0451d4a0eb5e5cbd5

fireeth tools firehose-client polygon.streamingfast.io:443 45772976 45772976 |jq . > polygon45772976.json grep -i 33315f4c921b9c1321448bcc23806742b7aee9081b5c7c96bdd8a097082a61de polygon45772976 ## this transaction should be there: https://polygonscan.com/tx/0x33315f4c921b9c1321448bcc23806742b7aee9081b5c7c96bdd8a097082a61de

polygon transactions are reordered here: https://github.com/streamingfast/firehose-ethereum/blob/develop/codec/console_reader.go#L993 https://github.com/streamingfast/firehose-ethereum/blob/develop/codec/postprocess.go#L156

sduchesneau commented 1 year ago

We have those 3 extraneous trxs, all at block index=1 "f6675f3059f9761b2aca8de2d8dfaa286d56cbbb01c0f5e691309115bfcb9096" "7a6f467d02f311522331afa4c39621f3f17878d67a342f59d349258ab8fd4873" "122953921e81fa17ea6e5760e8a61cb97a96826143a0e64601e720d2bff7d77c"

jubeless commented 1 year ago

Link to issue https://github.com/streamingfast/firehose-ethereum/issues/72

sduchesneau commented 1 year ago

explanation here https://github.com/streamingfast/firehose-ethereum/pull/74#issue-1877475671

sduchesneau commented 1 year ago

New PR fixes this. However, we discovered that firehose contains the details of another transaction that happens every 6400 blocks. it has no logs, but has some calls and lots of state changes. This difference between rpc and firehose provider will stay, as firehose allows access to ALL the state changes. This should not be an issue with TheGraph PoIs since polygon chain does not have CallHandlers or filtered BlockHandlers.

sduchesneau commented 1 year ago

Fixed here: https://github.com/streamingfast/firehose-ethereum/pull/74