This repository has been archived by the owner on Feb 1, 2024. It is now read-only.
[ad-hoc] [3](3) Rounding issues in mirror strategy causing offers to not be placed #541
Closed
4 tasks done
bids are not placed in most situations.
See line below, when dividing by price we may round up to get the normalizedPrimaryUnits and when we eventually multiply again to get back into the quote asset it ends up in a larger number because of this rounding. We want to round down in this case to be conservative, and to take a calculation that has a larger precision output, maybe even consider big.Rat temporarily
normalizedPrimaryUnits = normalizedPrimaryUnits.Divide(*price)
this causes the oversell statement to be triggered, and we don't retry in the mirror strategy yet
Related to #524
The text was updated successfully, but these errors were encountered: