Can a valid transaction fail on Radix?

I remember reading (in the whitepaper) that Radix uses deterministic consensus, as opposed to Ethereum and many other networks which use probabilistic consensus. So, as long as a transaction is valid (it can actually be submitted because the recipient is valid, the amount of tokens sending is valid, etc.) can it ever fail for any reason?

When submitting transactions through the API they get rejected before actually being sent to the network if they’re invalid e.g. if you don’t have enough XRD. Is there a situation where, say you were using the Core API https://raw.githubusercontent.com/radixdlt/radixdlt/1.2.2/radixdlt-core/radixdlt/src/main/java/com/radixdlt/api/core/api.yaml instead of the Gateway, where you could submit a transaction to the network but it gets rejected/reversed/fails?

1 Like

Yes, 99.9% of FAILED transactions get rejected at the Gateway API level.
There are situations when the API thinks that the transaction is OK so it gets submitted to the network just to fail there. An example of how to simulate it - send two conflicting (but different) transactions to different API nodes at the same time. One of them will succeed; another will fail.

However, the failed transactions are not written to the ledger, their status is tracked by the API node that was used to submit it. Here is what it looks like in the mempool_transactions table of the Gateway API:

7 Likes

Thanks, so if it makes it to the network, it will still fail “immediately”, not after some time like Ethereum?

I’m not sure how exactly that part works.