cartesi / rollups-contracts

Smart Contracts for Cartesi Rollups
https://cartesi.github.io/rollups-contracts/
Apache License 2.0
18 stars 38 forks source link

Refactor `VoucherExecuted` event #170

Closed guidanoli closed 8 months ago

guidanoli commented 9 months ago

📚 Context

Currently, the VoucherExecuted event from the ICartesiDApp interface has one argument, voucherId, which uniquely identifies the voucher that was executed. This number, however, isn't really helpful for off-chain components to tell which voucher was actually executed.

✔️ Solution

Vouchers can be identified with two numbers: input index and output index (within input). We can refactor the VoucherExecuted event to encode the two numbers mentioned as arguments.