Skip to content

Commit

Permalink
Merge bitcoin#29467: test: Fix intermittent issue in interface_rest.py
Browse files Browse the repository at this point in the history
faeed91 test: Fix intermittent issue in interface_rest.py (MarcoFalke)

Pull request description:

  Fixes:

  ```
   test  2024-02-22T16:15:37.465000Z TestFramework (ERROR): Assertion failed
    Traceback (most recent call last):
    File "/ci_container_base/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/test_framework.py", line 131, in main
     self.run_test()
    File "/ci_container_base/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/interface_rest.py", line 340, in run_test
     assert_equal(json_obj, mempool_info)
    File "/ci_container_base/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/util.py", line 57, in assert_equal
     raise AssertionError("not(%s)" % " == ".join(str(arg) for arg in (thing1, thing2) + args))
   AssertionError: not({'loaded': True, 'size': 3, 'bytes': 312, 'usage': 3600, 'total_fee': Decimal('0.00093600'), 'maxmempool': 300000000, 'mempoolminfee': Decimal('0.00001000'), 'minrelaytxfee': Decimal('0.00001000'), 'incrementalrelayfee': Decimal('0.00001000'), 'unbroadcastcount': 1, 'fullrbf': False} == {'loaded': True, 'size': 3, 'bytes': 312, 'usage': 3600, 'total_fee': Decimal('0.00093600'), 'maxmempool': 300000000, 'mempoolminfee': Decimal('0.00001000'), 'minrelaytxfee': Decimal('0.00001000'), 'incrementalrelayfee': Decimal('0.00001000'), 'unbroadcastcount': 0, 'fullrbf': False})
  ```

  https://cirrus-ci.com/task/4852944378527744?logs=ci#L4436

ACKs for top commit:
  m3dwards:
    ACK bitcoin@faeed91
  mzumsande:
    ACK faeed91

Tree-SHA512: 513422229db45d2586c554b9a466e86848bfcf5280b0f000718cbfc44d93dd1af69e19a56f6ac578f5d7aada74ab0c90d4a9e09a324062b6f9ed239e5e34f540
  • Loading branch information
fanquake committed Feb 26, 2024
2 parents ac19235 + faeed91 commit 60b6ff5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/functional/interface_rest.py
Original file line number Diff line number Diff line change
Expand Up @@ -337,6 +337,9 @@ def run_test(self):
assert_greater_than(json_obj['bytes'], 300)

mempool_info = self.nodes[0].getmempoolinfo()
# pop unstable unbroadcastcount before check
for obj in [json_obj, mempool_info]:
obj.pop("unbroadcastcount")
assert_equal(json_obj, mempool_info)

# Check that there are our submitted transactions in the TX memory pool
Expand Down

0 comments on commit 60b6ff5

Please sign in to comment.