-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Precision loss in JSON RPC due to using float #1558
Comments
On which Dogecoin Core version did you test this? Does this also happen on 1.14? |
I used 1.10 but will try 1.14. Was it fixed in 1.14? |
There have been so many changes in 1.14 I can't tell for sure but it might have been fixed there 😅 |
I'm trying to build a reproduction case, but have to admit normally I process transactions by taking the whole raw block off the client and then processing it in code, rather than than querying transactions individually. Mostly it's a lot faster, but also avoids issues like this. I suspect we have the same precision behavior as Bitcoin Core, but because our transaction values are much larger, floating point precision issues only show up in Dogecoin Core. Will check. |
Any ETA for when it will be fixed? We're building datasets in BigQuery which among others will include Dogecoin data, similar to this. It would be nice if I could still rely on JSON RPC instead of parsing raw transactions. |
You said you're going to try 1.14, did you? If it still happens there we can look into fixing it there. |
Sorry I didn't have a chance to verify it on 1.14. Was pretty confident it'd reproduce there since the fix of the analogous issue from Bitcoin bitcoin/bitcoin#6239 isn't merged to Dogecoin master. Will report here as soon as I have a chance to verify it. |
Amazing, it's not reproduced in 1.14.2. Could you point to the commit where it was fixed? |
1.14 was completely rebuilt based on Bitcoin Core 0.14, so it will have been from the Bitcoin code we've used as the base. |
Some transactions show negative fee because JSON RPC returns wrong value https://dogechain.info/tx/fddfe44a58de2432979e6ca340b2e0bffeebb3704edcf87f689bc057f6e5f358
84,841,299.38699999
is supposed to be84,841,299.38700000
The text was updated successfully, but these errors were encountered: