dymensionxyz / dymint

Sequencing Engine for Dymension RollApps
Other
90 stars 61 forks source link

multiple events recieved of hub batch acceptance cause subscription to get cancelled #838

Closed omritoptix closed 1 month ago

omritoptix commented 1 month ago

basically we're intolerant to hub emitting multiple events. this in turn cause subscription to get cancelled and for the submission function to return an err.

we need to be more tolerant about hub quircks. as agreed:

  1. increase buffer of subscription (currently its 1. We can do e.g 100)
  2. upon event arrival, validate it's actually the event we're waiting for in terms of start height, and only than return success.
srene commented 1 month ago

I think 1 is already solved in https://github.com/dymensionxyz/dymint/pull/773, by replacing subscriptions by unbuffered subscriptions.