zkopru-network / zkopru

Ethereum L2 scaling solution for private transactions using zk-SNARK and optimistic rollup.
https://zkopru.network
GNU General Public License v3.0
217 stars 28 forks source link

Fix in UtxoDeposit listener #407

Closed saleel closed 2 years ago

saleel commented 2 years ago

I think I have found an issue in the UtxoDeposit listener function in the synchronizer.

In the listenDepositUtxos function, while processing the existing blocks, if the owner of a DepositUtxo event is not one of the addresses being tracked, it exits the function (return statement). This prevent processing of all further events and blocks.

Moreover it prevents the code for attaching a subscriber to the future events being executed.

This PR changed the return statement to continue so only that particular event is skipped.

saleel commented 2 years ago

Update: Added some exports to @zkopru/clients package which could be useful for other projects building on top of Zkopru

saleel commented 2 years ago

Yea, I started investigating after having issue with the web wallet. Thanks. Merging now.