dcrdex icon indicating copy to clipboard operation
dcrdex copied to clipboard

evm assets: automatic re-redeem is not always desirable

Open buck54321 opened this issue 1 year ago • 4 comments

Automatically sending replacement transactions for failed execution redemptions is not always a good idea. During testing, we had an instance where our gas limits were too low. The redemptions were failing, and we just kept on submitting them about once per minute for eternity. On an asset like Ethereum, during a time of moderate to high fees, that could drain a wallet extremely quickly.

One solution could be to not automatically re-redeem, but return some kind of special error telling core that the redemption failed. Core could mark the match appropriately, and communicate the info to the front end, which would display a dialogue with controls for re-submission.

buck54321 avatar Sep 23 '23 01:09 buck54321

Can I work on this @buck54321? I think we can have like 1 - 3 trials before we give up and notify core? Also, this will require a new page(Pending Redeems) only for evm assets? Or better still all assets can stop at the said max trial for consistency and pending redems show on the FE? I'm also thinking about how best we can communicate this new change to legacy users/new users(Maybe a new note on the order confirmation form?).

ukane-philemon avatar Sep 23 '23 10:09 ukane-philemon

At first, let's just give up after 1 try, but allow another try on restart. No UI changes for now.

Or better still all assets can stop at the said max trial for consistency and pending redems show on the FE?

Not sure I fully understand, but no, we're not going to stop all assets for this error.

I'm also thinking about how best we can communicate this new change to legacy users/new users(Maybe a new note on the order confirmation form?).

Auto re-redeem is not in a release branch. We don't need to worry about legacy users.

buck54321 avatar Nov 02 '23 23:11 buck54321

Okay. The part where I talked about showing pending redeems on the FE was about allowing users to trigger a manual redeem from the UI if it failed the first time.

ukane-philemon avatar Nov 02 '23 23:11 ukane-philemon

@buck54321, It seems we also do auto-refunds. Do you think we only need to bother about auto-redeems?

ukane-philemon avatar Nov 07 '23 16:11 ukane-philemon