namecoin / namecoin-core

Namecoin full node + wallet based on the current Bitcoin Core codebase.
https://www.namecoin.org/
MIT License
463 stars 147 forks source link

auxpow_mining functional tests failing #396

Open JeremyRand opened 3 years ago

JeremyRand commented 3 years ago

The auxpow_mining.py tests are failing.

Expected behavior

Functional tests should succeed.

Actual behavior

191/196 - auxpow_mining.py failed, Duration: 1 s
stdout:
2021-01-21T08:19:22.953000Z TestFramework (INFO): Initializing test directory /tmp/cirrus-ci-build/ci/scratch/test_runner/test_runner_β‚Ώ_πŸƒ_20210121_081614/auxpow_mining_3
2021-01-21T08:19:23.615000Z TestFramework (ERROR): JSONRPC error
Traceback (most recent call last):
  File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/test_framework.py", line 126, in main
    self.run_test()
  File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/auxpow_mining.py", line 42, in run_test
    self.test_getauxblock ()
  File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/auxpow_mining.py", line 152, in test_getauxblock
    self.test_common (create, submit)
  File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/auxpow_mining.py", line 52, in test_common
    auxblock = create ()
  File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/coverage.py", line 47, in __call__
    return_val = self.auth_service_proxy_instance.__call__(*args, **kwargs)
  File "/tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/authproxy.py", line 146, in __call__
    raise JSONRPCException(response['error'], status)
test_framework.authproxy.JSONRPCException: Method not found (-32601)
2021-01-21T08:19:23.620000Z TestFramework (INFO): Stopping nodes
2021-01-21T08:19:23.829000Z TestFramework (WARNING): Not cleaning up dir /tmp/cirrus-ci-build/ci/scratch/test_runner/test_runner_β‚Ώ_πŸƒ_20210121_081614/auxpow_mining_3
2021-01-21T08:19:23.830000Z TestFramework (ERROR): Test failed. Test logging available at /tmp/cirrus-ci-build/ci/scratch/test_runner/test_runner_β‚Ώ_πŸƒ_20210121_081614/auxpow_mining_3/test_framework.log
2021-01-21T08:19:23.830000Z TestFramework (ERROR): 
2021-01-21T08:19:23.830000Z TestFramework (ERROR): Hint: Call /tmp/cirrus-ci-build/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/combine_logs.py '/tmp/cirrus-ci-build/ci/scratch/test_runner/test_runner_β‚Ώ_πŸƒ_20210121_081614/auxpow_mining_3' to consolidate all logs
2021-01-21T08:19:23.830000Z TestFramework (ERROR): 
2021-01-21T08:19:23.830000Z TestFramework (ERROR): If this failure happened unexpectedly or intermittently, please file a bug and provide a link or upload of the combined log.
2021-01-21T08:19:23.830000Z TestFramework (ERROR): https://github.com/bitcoin/bitcoin/issues
2021-01-21T08:19:23.831000Z TestFramework (ERROR): 

See https://cirrus-ci.com/task/6006589205250048 for an example.

To reproduce

Run the [no wallet] [bionic] task on Cirrus.

System information

Namecoin Core auxpow branch, commit hash 8e81ee2da2e396a9bb61d0a645a444521397b831, built on Cirrus.

I would not be surprised if this failure is because the AuxPoW code is incorrectly relying on wallet code.

domob1812 commented 3 years ago

Since it passes with a wallet, I assume your guess is likely correct somehow. I can check it out at some point when I get time.

domob1812 commented 3 years ago

The issue actually is not that auxpow code requires the wallet, but just the auxpow regtest (for getauxblock and also e.g. to create a test transaction). So this is likely fixed with https://github.com/namecoin/namecoin-core/commit/8988418b5c48661a343a3f3ced94c82239554d69. @JeremyRand please confirm and close this issue accordingly.