-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: Remove SellAmount::AfterFee enum #2589
Comments
I agree that with all orders being limit orders this enum makes less sense (since the fee that is being returned is not guaranteed, so you may end up selling a bit more or less in the end), but I don't think it's worth the effort to remove it. This would require a breaking API change which I think should be held off for a v2 of the API (potentially in combination with a new settlement contract). |
We can keep it in API only, while removing from all the internal code (for code clarity). |
This issue has been marked as stale because it has been inactive a while. Please update this issue or it will be automatically closed. |
Background
https://github.com/cowprotocol/services/blob/main/crates/model/src/quote.rs#L257-L268
AFAIU the point of this enum is to differentiate between (legacy) market and limit orders quote requests.
Now that we killed legacy market orders, we should also clean this up and remove enum.
I personally find it very hard to understand quotes with this enum, as it is complicated to deduct how the values are propagated throughout the codebase.
The text was updated successfully, but these errors were encountered: