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

[test] Round target fee to 8 decimals in assert_fee_amount #12486

Merged
merged 1 commit into from
Feb 23, 2018

Conversation

kallewoof
Copy link
Contributor

The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:

AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)

The above looks like the expected fee is 6175 sats when in reality it's 618.

@kallewoof kallewoof changed the title [test] Round target fee to 8 decimals [test] Round target fee to 8 decimals in assert_fee_amount Feb 20, 2018
The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
The above looks like the expected fee is 6175 sats when in reality it's 618.
@kallewoof kallewoof force-pushed the round-assert-fee-amount-target-fee branch from 8de519f to 42e1b5d Compare February 20, 2018 04:22
@fanquake fanquake added the Tests label Feb 20, 2018
@randolf
Copy link
Contributor

randolf commented Feb 20, 2018

Are there other similar places in the code where this kind of change can/should be implemented? (I'm thinking for future Pull Requests.)

@kallewoof
Copy link
Contributor Author

Probably, yeah. I didn't go hunting for them, just fixed this one as it was in my face (and confused me due to thinking the expected was 10x+ the result).

@maflcko
Copy link
Member

maflcko commented Feb 20, 2018

utACK 42e1b5d

@randolf
Copy link
Contributor

randolf commented Feb 21, 2018

@kallewoof I'm glad that you found it and fixed it. :)

@laanwj
Copy link
Member

laanwj commented Feb 23, 2018

utACK 42e1b5d

@laanwj laanwj merged commit 42e1b5d into bitcoin:master Feb 23, 2018
laanwj added a commit that referenced this pull request Feb 23, 2018
42e1b5d [test] Round target fee to 8 decimals in assert_fee_amount (Karl-Johan Alm)

Pull request description:

  The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
  ```
  AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
  ```
  The above looks like the expected fee is 6175 sats when in reality it's 618.

Tree-SHA512: ddbff2926a88890d6e34a58db36f0b15a917a80064be6e40e9bcbec3f05ae6202d02adcd7873733945b043fa121d4a56dd930446ec368078fe1935cbfff898ce
maflcko pushed a commit to maflcko/bitcoin-core that referenced this pull request Apr 20, 2018
The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
The above looks like the expected fee is 6175 sats when in reality it's 618.

Github-Pull: bitcoin#12486
Rebased-From: 42e1b5d
HashUnlimited pushed a commit to chaincoin/chaincoin that referenced this pull request May 13, 2018
The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
The above looks like the expected fee is 6175 sats when in reality it's 618.

Github-Pull: bitcoin#12486
Rebased-From: 42e1b5d
@kallewoof kallewoof deleted the round-assert-fee-amount-target-fee branch October 17, 2019 08:38
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Mar 14, 2020
…fee_amount

42e1b5d [test] Round target fee to 8 decimals in assert_fee_amount (Karl-Johan Alm)

Pull request description:

  The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
  ```
  AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
  ```
  The above looks like the expected fee is 6175 sats when in reality it's 618.

Tree-SHA512: ddbff2926a88890d6e34a58db36f0b15a917a80064be6e40e9bcbec3f05ae6202d02adcd7873733945b043fa121d4a56dd930446ec368078fe1935cbfff898ce
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Mar 19, 2020
…fee_amount

42e1b5d [test] Round target fee to 8 decimals in assert_fee_amount (Karl-Johan Alm)

Pull request description:

  The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
  ```
  AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
  ```
  The above looks like the expected fee is 6175 sats when in reality it's 618.

Tree-SHA512: ddbff2926a88890d6e34a58db36f0b15a917a80064be6e40e9bcbec3f05ae6202d02adcd7873733945b043fa121d4a56dd930446ec368078fe1935cbfff898ce
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Mar 21, 2020
…fee_amount

42e1b5d [test] Round target fee to 8 decimals in assert_fee_amount (Karl-Johan Alm)

Pull request description:

  The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
  ```
  AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
  ```
  The above looks like the expected fee is 6175 sats when in reality it's 618.

Tree-SHA512: ddbff2926a88890d6e34a58db36f0b15a917a80064be6e40e9bcbec3f05ae6202d02adcd7873733945b043fa121d4a56dd930446ec368078fe1935cbfff898ce
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Mar 24, 2020
…fee_amount

42e1b5d [test] Round target fee to 8 decimals in assert_fee_amount (Karl-Johan Alm)

Pull request description:

  The output would produce arbitrary number of decimal points, sometimes resulting in 9 decimals:
  ```
  AssertionError: Fee of 0.00000415 BTC too low! (Should be 0.000006175 BTC)
  ```
  The above looks like the expected fee is 6175 sats when in reality it's 618.

Tree-SHA512: ddbff2926a88890d6e34a58db36f0b15a917a80064be6e40e9bcbec3f05ae6202d02adcd7873733945b043fa121d4a56dd930446ec368078fe1935cbfff898ce
maflcko pushed a commit to maflcko/bitcoin-core that referenced this pull request Oct 1, 2021
…nctional test framework

b658d7d test: update assert_fee_amount() in test_framework/util.py (Jon Atack)

Pull request description:

  Follow-up to 42e1b5d (bitcoin#12486).
  - update call to `round()` with our utility function `satoshi_round()` to avoid intermittent test failures
  - rename `fee_per_kB` to `feerate_BTC_kvB` for precision
  - store division result in `feerate_BTC_vB`

  Possibly resolves bitcoin#19418.

ACKs for top commit:
  meshcollider:
    utACK b658d7d

Tree-SHA512: f124ded98c913f98782dc047a85a05d3fdf5f0585041fa81129be562138f6261ec1bd9ee2af89729028277e75b591b0a7ad50244016c2b2fa935c6e400523183
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Dec 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants