algorand / indexer

searchable history and current state
MIT License
114 stars 92 forks source link

Some inner PAY transactions have incorrect metadata. #1561

Closed urtho closed 1 year ago

urtho commented 1 year ago

Subject of the issue

There are around 80K inner transactions with incorrect metadata in the indexer. Parent's JSON has all the correct inners but the companion rows with root pointing to this parent are missing PAY metadata resulting in missing receiver address and amount (or other info in case of close) Typeenum is OK but other data is missing/incorrect.

Example row: select * from txn where round = 19378233 and intra = 154

This has no impact on indexer API as inners are sourced from parent's metadata not from rows with TXID==NULL. But SQL data is incorrect for at least ~80K rows.

Expected behaviour

TX rows with standalone inners should have matching metadata instead of the parent's partial APP call metadata.

urtho commented 1 year ago

The issue seems to exist only for some old round range : 17431491..19619148 Maybe reindexing from scratch is going to solve this for me.

winder commented 1 year ago

This resulted from a bug fixed in Indexer 2.8.3 (early 2022). Inner transaction data written prior to that release has the wrong transaction data. There are some details here: https://github.com/algorand/indexer/issues/1292

urtho commented 1 year ago

Yeah - so my bad - I did not reindex after the bugfix.