Skip to content
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

TICK_SIZE - waves.exchange #13689

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
Open

Conversation

ttodua
Copy link
Member

@ttodua ttodua commented Jun 7, 2022

this PR updates the too old implementation of complex custom precision manipulations (the last edits were 4 years old, probably the Precise class was not developed well by that time).

This PR solves:

  1. moves exchange from DECIMAL_PLACES to TICK_SIZE.

  2. there were many scattered methods in the implementation: customPriceToPrecision, customAmountToPrecision, customCurrencyToPrecision, fromPrecision, toPrecision, currencyFromPrecision, priceFromPrecision ... 🤯 .

Now I've implemented the simpler : fromReal / toReal methods (for market amount & price and currency amount)

  1. fixes withdraw, createOrder and few others. I've tested all methods (public & private) and all seems to be working well.

js/wavesexchange.js Outdated Show resolved Hide resolved
@ttodua
Copy link
Member Author

ttodua commented Jul 4, 2022

@kroitor I've run private tests (no issues) and also made a test order (works as expected).

@ttodua

This comment was marked as resolved.

@ttodua ttodua changed the title TICK_SIZE - wavesexchange TICK_SIZE - waves.exchange Sep 8, 2022
@ttodua ttodua added the important Higher priority label Oct 28, 2022
@ttodua

This comment was marked as resolved.

@ttodua ttodua removed the important Higher priority label Nov 24, 2022
@ttodua ttodua marked this pull request as draft March 7, 2024 18:53
@ttodua

This comment was marked as outdated.

@ttodua ttodua assigned carlosmiei and unassigned kroitor May 15, 2024
@ttodua ttodua marked this pull request as ready for review May 15, 2024 15:40
@ttodua ttodua marked this pull request as draft May 15, 2024 18:34
@ttodua ttodua marked this pull request as ready for review May 16, 2024 16:04
@ttodua
Copy link
Member Author

ttodua commented May 16, 2024

@carlosmiei passes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

3 participants