I can emit the right DuskVM event and still ship a backend that cannot read it.
The hidden step is Forge registration. dusk_core::abi::emit(topic, value) puts the event into execution, but emission alone does not add it to the generated schema. For the data driver to decode that event, I still have to define the serializable event type, implement ContractEvent, register it in #[dusk_forge::contract(events = [...])], then emit that registered type.
Miss one of those links and the contract can execute correctly while the integration loses the readable event surface it depends on.
The consequence I care about is a redemption stuck in the app after it already completed on-chain. The contract state moved. The user’s transaction finalized. My backend is still waiting because the event bytes have no generated decoder it knows how to use.
I would test the event from outside the contract: build the driver, inspect the schema, decode the emitted bytes, then let the redemption UI depend on it.
On DuskVM, “event emitted” is not the finish line. “Event decoded by the consumer” is.
#dusk $DUSK @Dusk
The hidden step is Forge registration. dusk_core::abi::emit(topic, value) puts the event into execution, but emission alone does not add it to the generated schema. For the data driver to decode that event, I still have to define the serializable event type, implement ContractEvent, register it in #[dusk_forge::contract(events = [...])], then emit that registered type.
Miss one of those links and the contract can execute correctly while the integration loses the readable event surface it depends on.
The consequence I care about is a redemption stuck in the app after it already completed on-chain. The contract state moved. The user’s transaction finalized. My backend is still waiting because the event bytes have no generated decoder it knows how to use.
I would test the event from outside the contract: build the driver, inspect the schema, decode the emitted bytes, then let the redemption UI depend on it.
On DuskVM, “event emitted” is not the finish line. “Event decoded by the consumer” is.
#dusk $DUSK @Dusk