Removing Collaborative Cancellations #758
LayneHaber
started this conversation in
Archive
Replies: 2 comments 5 replies
-
|
Beta Was this translation helpful? Give feedback.
5 replies
-
No longer relevant in the new designs |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summary
Right now if a router cancels a payment pre-expiry on the sender side (i.e. they can no longer serve those prices, or user cancelled receiver), they are exposed to the gas costs. This means any collaboratively cancelled transaction is a net loss for the router. Additionally, the expiry ranges are set as
immutable
without any way to update them based on production data. Instead, collaborative cancels should be removed and the expiries should be much shorter, and tunable.Motivation
At present routers face irrecoverable costs to cancel a transaction, even if they are doing everything correctly. Imagine a router that submits a bid, but is not able to fulfill it until the pricing has expired (i.e. now the slippage would be out of the bounds set in the bid). The correct thing for the router to do is to cancel the user's payment pre-expiry, but this will cost gas they do not get reimbursed or take fees for.
Proposed Solution
The best solution here would be to decrease the minimum expiry on the sender side and remove collaborative (pre-expiry) cancellations completely. The main purpose behind collaborative cancellations was to release funds in a reasonable time. If we are able to reduce the minimum expiry, the UX can still be preserved without the routers paying funds for cancellations. An additional consideration would be to allow for fulfillment post-expiry rather than only allowing cancellations. This way, transfers with non-malicious users would be able to be fulfilled on the sending chain even after the expiry.
Additionally, as we move towards auctionless routing users will no longer need to wait for a given router and the chances of a transaction being properly prepared increase.
To implement this:
Tests
The following should be implemented:
Outstanding Questions
Tasks
minTimeout
configurablemaxTimeout
configurablecancel
cancel
fulfill
Beta Was this translation helpful? Give feedback.
All reactions