Repository navigation
Merged
Conversation
luke-jr
reviewed
Sep 29, 2020
Author
|
Made the changes in ba15b84 Was even thinking about adding |
ghost
marked this pull request as ready for review
October 3, 2020 02:08
Contributor
|
Concept ACK |
Contributor
|
Concept ACK, but should squash the commits, I think. |
guggero
reviewed
Oct 21, 2020
guggero
reviewed
Oct 21, 2020
guggero
left a comment
Contributor
There was a problem hiding this comment.
ACK 3afdc9bd - assuming commits are being squashed on merge.
maflcko
reviewed
Oct 21, 2020
Member
|
Please squash your commits according to https://github.com/bitcoin/bitcoin/blob/master/CONTRIBUTING.md#squashing-commits |
+ fee, fee_expected, output_amount + Using value of coin['amount'] as decimal and removed 'int' + Removed unnecessary parentheses + Remove str() and use quotes
Contributor
|
ACK 5aadd4b |
deadalnix
pushed a commit
to Bitcoin-ABC/bitcoin-abc
that referenced
this pull request
Dec 6, 2021
Summary: Use python `Decimal` when defining fees and amounts. This ensures that subsequent operations on these amounts produces exact decimal amount, without potential rounding errors, instead of floats. This is a backport of [[bitcoin/bitcoin#20039 | core#20039]] Test Plan: `ninja check-functional` Reviewers: #bitcoin_abc, Fabien Reviewed By: #bitcoin_abc, Fabien Subscribers: Fabien Differential Revision: https://reviews.bitcoinabc.org/D10599
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
https://docs.python.org/3.8/library/decimal.html
Decimal type saves an exact value so better than using float.
3 variables declared with type as 'Decimal' in test/functional/mempool_accept.py: fee, fee_expected, output_amountNot required to convert to string anymore for using the above variables as decimal+ 8 decimal placesFixes #20011