Replace usages of DecimalConstants with metadata lookup #415
Labels
No labels
blocked
breaking
bug
dependencies
duplicate
enhancement
good first issue
help wanted
question
tech debt
testing
wontfix
No milestone
No project
No assignees
1 participant
Due date
No due date set.
Dependencies
No dependencies set.
Reference
scion/arbitrader#415
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The
DecimalConstantswe use to get a BTC scaleof 8 or a USD scale of 2 are incorrect for other currencies. The correct way is to look at the metadata onCurrencyorCurrencyPair, look at whether it's a volume scale or a price scale and return what we find there if it's available.If it isn't available, we need a way for users to configure the missing data themselves rather than waiting for XChange to provide it in the next update (since that can take a month or more).
Finally we need to fall back to some kind of sane default value, but it's likely to be wrong in most cases. A reasonable guess would be 8 for crypto and 2 for fiat.