I have attempted to send multiple transactions, using both universal and custom channels, but they are all in relaying status. I don’t know how to fix it.
Tx in OP:
Contract in base:
I have attempted to send multiple transactions, using both universal and custom channels, but they are all in relaying status. I don’t know how to fix it.
Tx in OP:
Contract in base:
Hey @scriptmoney, it seems like the packet is never being received by the destination chain. This could be due to a couple different issues.
It appears the channel connection is set up correctly.
One possible debugging step that could help identify the route cause of the issue is to emit events on onRecvPacket
in the Reward smart contract on destination chain and then on onAcknowledgementPacket
on the BetNBA contract in the source chain. This could help identify if the packet is being encoded and decoded properly when getting sent between chains.
Hope this helps!
@kenobi I have added events, could you check again?
op source contract: 0x3EAd6F519fF9a5620699e98Ab5B345C466240d97
base target contract: 0xdaDe145E44423C5327805ccDB273138264068007
Looking into it. Seems from our internal relayer logs that the sendPacket event reaches Polymer, Polymer emits a RecvPacket event but then the flow stops…
Will also try to reproduce locally. We’ll keep you posted
Sorry, I know where the problem is. I did not call addMatch on the base chain, and when receiving the packet, it should not meet require(matchMap[_matchId[i]].id != 0, "Match not found");
Good to hear your captured the bug!
Still, the point holds that these silent failures need improvement.
We’re working towards a solution by adding some try catch logic on dispatcher contract when calling the packet lifecycle callbacks.
These will be added in an update soon to make debugging easier