Skip to content

Upgrade setuptools

Thomas Binétruy-Pic requested to merge fix/failed-onchain-originations into rebase2

The following transactions blocked the entire indexer:

Interestingly, these transactions do NOT need to be « tracked » by the indexer, as in the sender does have to be in the Accounts table to even break the indexer service. Indeed, we can see in the fix that if the an origination transaction "failed" and is on-chain, then it's not possible to retrieve its origination address (since it failed) and check if the transaction is tracked or not.

The indexer service fails with:

> address = result['originated_contracts'][0]
E KeyError: 'originated_contracts'

This fix handles two cases:

  • either the transaction was spooled, and the hash should be in the TezosTransaction table, in which case we retrieve the transaction and update its state to "failed" (which we added to in the model) and update its error state. Note that this should case is extremly rare as Pytezos will dry run the origination before sending it to the node such that it should not be included on chain. However, such a case could happen if the origination failes in a way that could not be determined by the dry run (gas exhaust, out of tz because of other tx from the same sender earlier in the block etc).
  • the transaction was not spooled and is not tracked, in which case we simply skip it.

Merge request reports

Loading