Page MenuHomePhabricator

extract/rename helper functions from rpc_packages.py
ClosedPublic

Authored by PiRK on Oct 5 2022, 16:12.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC3e95491fd5f3: extract/rename helper functions from rpc_packages.py
Summary

MOVEONLY; no change in behavior. Rename because there is another helper
function in chain_transaction in test_framework.util.py

This is a backport of core#21800 [6/9]
https://github.com/bitcoin/bitcoin/pull/21800/commits/f8253d69d6f02850995a11eeb71fedc22e6f6575

Notes:

  • Commit backported out of order (refactorings first)
  • due to missing backports, we don't have the tx_from_hex helper function
Test Plan

ninja check-functional

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

PiRK requested review of this revision.Oct 5 2022, 16:12

Failed tests logs:

====== Bitcoin ABC functional tests: feature_utxo_set_hash.py ======

------- Stdout: -------
2022-10-05T16:21:36.263000Z TestFramework (INFO): Initializing test directory /work/abc-ci-builds/build-without-wallet/test/tmp/test_runner_₿₵_  _20221005_161932/feature_utxo_set_hash_162
2022-10-05T16:21:36.521000Z TestFramework (INFO): Test MuHash implementation consistency
2022-10-05T16:21:36.753000Z TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/work/test/functional/test_framework/test_framework.py", line 132, in main
    self.run_test()
  File "/work/test/functional/feature_utxo_set_hash.py", line 74, in run_test
    self.test_muhash_implementation()
  File "/work/test/functional/feature_utxo_set_hash.py", line 67, in test_muhash_implementation
    assert_equal(finalized[::-1].hex(), node_muhash)
  File "/work/test/functional/test_framework/util.py", line 61, in assert_equal
    raise AssertionError("not({})".format(" == ".join(str(arg)
AssertionError: not(a6911663f4bdc4c4d17fdd0d2f6bd09b5709a18f82faf1e48af2724072394373 == b906cdb304fe1bbc64af281d9a039b0f0eaab954e1f9ac53d4eee3b7a2b89672)
2022-10-05T16:21:36.804000Z TestFramework (INFO): Stopping nodes
2022-10-05T16:21:36.905000Z TestFramework (WARNING): Not cleaning up dir /work/abc-ci-builds/build-without-wallet/test/tmp/test_runner_₿₵_  _20221005_161932/feature_utxo_set_hash_162
2022-10-05T16:21:36.905000Z TestFramework (ERROR): Test failed. Test logging available at /work/abc-ci-builds/build-without-wallet/test/tmp/test_runner_₿₵_  _20221005_161932/feature_utxo_set_hash_162/test_framework.log
2022-10-05T16:21:36.905000Z TestFramework (ERROR): 
2022-10-05T16:21:36.905000Z TestFramework (ERROR): Hint: Call /work/test/functional/combine_logs.py '/work/abc-ci-builds/build-without-wallet/test/tmp/test_runner_₿₵_  _20221005_161932/feature_utxo_set_hash_162' to consolidate all logs
2022-10-05T16:21:36.905000Z TestFramework (ERROR): 
2022-10-05T16:21:36.905000Z TestFramework (ERROR): If this failure happened unexpectedly or intermittently, please file a bug and provide a link or upload of the combined log.
2022-10-05T16:21:36.905000Z TestFramework (ERROR): https://github.com/Bitcoin-ABC/bitcoin-abc/issues
2022-10-05T16:21:36.905000Z TestFramework (ERROR):

Each failure log is accessible here:
Bitcoin ABC functional tests: feature_utxo_set_hash.py

Failed tests logs:

====== Bitcoin ABC functional tests: feature_utxo_set_hash.py ======

------- Stdout: -------
2022-10-05T16:22:18.012000Z TestFramework (INFO): Initializing test directory /work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20221005_161619/feature_utxo_set_hash_162
2022-10-05T16:22:18.543000Z TestFramework (INFO): Test MuHash implementation consistency
2022-10-05T16:22:19.084000Z TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/work/test/functional/test_framework/test_framework.py", line 132, in main
    self.run_test()
  File "/work/test/functional/feature_utxo_set_hash.py", line 74, in run_test
    self.test_muhash_implementation()
  File "/work/test/functional/feature_utxo_set_hash.py", line 67, in test_muhash_implementation
    assert_equal(finalized[::-1].hex(), node_muhash)
  File "/work/test/functional/test_framework/util.py", line 61, in assert_equal
    raise AssertionError("not({})".format(" == ".join(str(arg)
AssertionError: not(69287de78cdff52418fbbf67be12aada3caab5b288b7200550a78e9ac218f20d == c7000c47b9a9816313c0ae6aa135a9f59bb689bae7b2e595d65cac16de5e5c7b)
2022-10-05T16:22:19.135000Z TestFramework (INFO): Stopping nodes
2022-10-05T16:22:19.337000Z TestFramework (WARNING): Not cleaning up dir /work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20221005_161619/feature_utxo_set_hash_162
2022-10-05T16:22:19.337000Z TestFramework (ERROR): Test failed. Test logging available at /work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20221005_161619/feature_utxo_set_hash_162/test_framework.log
2022-10-05T16:22:19.337000Z TestFramework (ERROR): 
2022-10-05T16:22:19.337000Z TestFramework (ERROR): Hint: Call /work/test/functional/combine_logs.py '/work/abc-ci-builds/build-debug/test/tmp/test_runner_₿₵_  _20221005_161619/feature_utxo_set_hash_162' to consolidate all logs
2022-10-05T16:22:19.337000Z TestFramework (ERROR): 
2022-10-05T16:22:19.337000Z TestFramework (ERROR): If this failure happened unexpectedly or intermittently, please file a bug and provide a link or upload of the combined log.
2022-10-05T16:22:19.337000Z TestFramework (ERROR): https://github.com/Bitcoin-ABC/bitcoin-abc/issues
2022-10-05T16:22:19.337000Z TestFramework (ERROR):

Each failure log is accessible here:
Bitcoin ABC functional tests: feature_utxo_set_hash.py

PiRK planned changes to this revision.Oct 5 2022, 16:27

this needs rebasing. My master was wrong when i started my branch.

Failed tests logs:

====== Bitcoin ABC functional tests: feature_utxo_set_hash.py ======

------- Stdout: -------
2022-10-05T16:22:21.186000Z TestFramework (INFO): Initializing test directory /work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_161802/feature_utxo_set_hash_162
2022-10-05T16:22:21.468000Z TestFramework (INFO): Test MuHash implementation consistency
2022-10-05T16:22:21.706000Z TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/work/test/functional/test_framework/test_framework.py", line 132, in main
    self.run_test()
  File "/work/test/functional/feature_utxo_set_hash.py", line 74, in run_test
    self.test_muhash_implementation()
  File "/work/test/functional/feature_utxo_set_hash.py", line 67, in test_muhash_implementation
    assert_equal(finalized[::-1].hex(), node_muhash)
  File "/work/test/functional/test_framework/util.py", line 61, in assert_equal
    raise AssertionError("not({})".format(" == ".join(str(arg)
AssertionError: not(7cff1a1ab5ccaee14ed0b2d7e43e5692844945ef58dad481d3c3e1ce344f3edf == c86d0a0f6a4cd9e7f3a54526a831d30cdb8a23d4e7d68e92d227de4aa82c4799)
2022-10-05T16:22:21.758000Z TestFramework (INFO): Stopping nodes
2022-10-05T16:22:22.062000Z TestFramework (WARNING): Not cleaning up dir /work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_161802/feature_utxo_set_hash_162
2022-10-05T16:22:22.062000Z TestFramework (ERROR): Test failed. Test logging available at /work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_161802/feature_utxo_set_hash_162/test_framework.log
2022-10-05T16:22:22.062000Z TestFramework (ERROR): 
2022-10-05T16:22:22.062000Z TestFramework (ERROR): Hint: Call /work/test/functional/combine_logs.py '/work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_161802/feature_utxo_set_hash_162' to consolidate all logs
2022-10-05T16:22:22.062000Z TestFramework (ERROR): 
2022-10-05T16:22:22.062000Z TestFramework (ERROR): If this failure happened unexpectedly or intermittently, please file a bug and provide a link or upload of the combined log.
2022-10-05T16:22:22.062000Z TestFramework (ERROR): https://github.com/Bitcoin-ABC/bitcoin-abc/issues
2022-10-05T16:22:22.062000Z TestFramework (ERROR):
====== Bitcoin ABC functional tests with the next upgrade activated: feature_utxo_set_hash.py ======

------- Stdout: -------
2022-10-05T16:26:17.673000Z TestFramework (INFO): Initializing test directory /work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_162235/feature_utxo_set_hash_162
2022-10-05T16:26:17.955000Z TestFramework (INFO): Test MuHash implementation consistency
2022-10-05T16:26:18.200000Z TestFramework (ERROR): Assertion failed
Traceback (most recent call last):
  File "/work/test/functional/test_framework/test_framework.py", line 132, in main
    self.run_test()
  File "/work/test/functional/feature_utxo_set_hash.py", line 74, in run_test
    self.test_muhash_implementation()
  File "/work/test/functional/feature_utxo_set_hash.py", line 67, in test_muhash_implementation
    assert_equal(finalized[::-1].hex(), node_muhash)
  File "/work/test/functional/test_framework/util.py", line 61, in assert_equal
    raise AssertionError("not({})".format(" == ".join(str(arg)
AssertionError: not(be8ae50f002eb881046dab63a1a086100d4c0436295057aad59de5c59d1a538f == f5cea18bd4b1accfb7183d1edbd8625dc16f751c25a3d5707435b6e9264884c2)
2022-10-05T16:26:18.250000Z TestFramework (INFO): Stopping nodes
2022-10-05T16:26:18.502000Z TestFramework (WARNING): Not cleaning up dir /work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_162235/feature_utxo_set_hash_162
2022-10-05T16:26:18.502000Z TestFramework (ERROR): Test failed. Test logging available at /work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_162235/feature_utxo_set_hash_162/test_framework.log
2022-10-05T16:26:18.502000Z TestFramework (ERROR): 
2022-10-05T16:26:18.502000Z TestFramework (ERROR): Hint: Call /work/test/functional/combine_logs.py '/work/abc-ci-builds/build-diff/test/tmp/test_runner_₿₵_  _20221005_162235/feature_utxo_set_hash_162' to consolidate all logs
2022-10-05T16:26:18.502000Z TestFramework (ERROR): 
2022-10-05T16:26:18.502000Z TestFramework (ERROR): If this failure happened unexpectedly or intermittently, please file a bug and provide a link or upload of the combined log.
2022-10-05T16:26:18.502000Z TestFramework (ERROR): https://github.com/Bitcoin-ABC/bitcoin-abc/issues
2022-10-05T16:26:18.502000Z TestFramework (ERROR):

Each failure log is accessible here:
Bitcoin ABC functional tests: feature_utxo_set_hash.py
Bitcoin ABC functional tests with the next upgrade activated: feature_utxo_set_hash.py

This revision is now accepted and ready to land.Oct 6 2022, 07:23