3ba602672c refactor: use self.wait_until in all the dash specific "wait_until_x" logic in order to actually apply the timeout scaling settings (pasta)
Pull request description:
## Issue being fixed or feature implemented
Currently we use the raw helper, but that means that timeout scaling isn't applying.. I think this may be a cause of a lot of the functional test failures that we see in tsan / ubsan.
## What was done?
## How Has This Been Tested?
hasn't; wait for CI
## Breaking Changes
## Checklist:
_Go over all the following points, and put an `x` in all the boxes that apply._
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional/e2e tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
knst:
utACK 3ba602672c
UdjinM6:
utACK 3ba602672c
Tree-SHA512: 935498f4b296b1abcac8be686cce396b61b654ef62da46de9a23a0f24ad31254f4938a581a6a4e2533576db0e0120861fd690bd9019e893b30990f21d1e48168
d4e36ae80d4b3f03647fd9057461edf7ecd794a3 test: Update --tmpdir doc string to say directory must not exist (kevkevin)
Pull request description:
The error message given if passing an existing dir to --tmpdir is confusing so this makes it clear that the directory must not already exist
This change is motivated by this comment https://github.com/bitcoin/bitcoin/pull/29335#issuecomment-1960913020
ACKs for top commit:
maflcko:
lgtm ACK d4e36ae80d4b3f03647fd9057461edf7ecd794a3
davidgumberg:
ACK d4e36ae80d
Tree-SHA512: fb31fd079767abbf94076615817943f35f5c9262fc97e65c631a18d33b3a343fe6a2d151613256e632d2b372ab2de0435f4712309b4a77ed3c663fd93a7dcdd1
4d84eaec82e7b5a450d47cd30e5936a717035f77 Raise PRNG seed log to INFO. (roconnor-blockstream)
Pull request description:
Some build infrastructure, such as Nix, will delete failed builds by default, keeping only the log (stdout/stderr) of the failed build.
For flaky tests, it would be very helpful to have the PRNG seed in the default log in order to redo the failed test.
By simply raising the PRNG seed logging to INFO, we can, by default, record the seed in the log of every build.
ACKs for top commit:
MarcoFalke:
lgtm ACK 4d84eaec82e7b5a450d47cd30e5936a717035f77
theStack:
ACK 4d84eaec82e7b5a450d47cd30e5936a717035f77
Tree-SHA512: 3ccb4a4e7639a3babc3b2a6456a6d0bffc090da34e4545b317f7bfbed4e9950d1b38ea5b2a90c37ccb49b3454bdeff03a6aaf86770b9c4dd14b26320aba50b94
6d4a782756 refactor: make dash specific args `sporkkey` and `dip3params` resilient for dashd restart (Konstantin Akimov)
7eaa0cf9ca refactor: simplify extra arguments wallet_mnemonicbits.py since usehd=1 is default option (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
DashTestFramework requires 2 arguments for dashd which are lost every dashd restart: `sporkkey` and `dip3params`.
Without this PR you need to pass this arguments manually every time when you restart dashd in functional tests.
## What was done?
Make dash specific args `sporkkey` and `dip3params` resilient for dashd restart
It makes workarounds such as [these](c28b05c5ca) no more needed:
```
self.restart_node(1, self.extra_args[1] + ["-checkaddrman=1"])
```
Also there's some cleanup for `wallet_mnemonicbits.py` to remove `usehd=1` which is not required, and it has been discovered during revising all node's restarts related code.
## How Has This Been Tested?
Removed workaround from `rpc_net.py` and run functional tests
## Breaking Changes
N/A
## Checklist:
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [x] I have added or updated relevant unit/integration/functional/e2e tests
- [x] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone
ACKs for top commit:
UdjinM6:
utACK 6d4a782756
PastaPastaPasta:
utACK 6d4a782756
Tree-SHA512: 638b2dfe45aa35d7a9c9b4e527c3211b47e8f2fc97caf130eae09ee348d539b4c73007be0e3949ac978e306d394d9ead1d63bda3f4b515335cc62c32d2635e62
131d16133c test: cleanup `generate` logic in some governance functional tests (Kittywhiskers Van Gogh)
dfeeb34d18 test: remove redundant sync after `generate*` calls in Bitcoin tests (Kittywhiskers Van Gogh)
a99a39ce8d test: remove redundant sync after `generate*` calls in Dash tests (Kittywhiskers Van Gogh)
1367115f7b test: opt-out of post-`generate*` syncing in some Dash tests (Kittywhiskers Van Gogh)
82da45a8bf test: move differing sync logic into `sync_fun` lambda in Dash tests (Kittywhiskers Van Gogh)
9b3fbdde10 merge bitcoin#23300: Implicitly sync after generate*, unless opted out (Kittywhiskers Van Gogh)
e913a45eaf test: remove redundant `self.nodes` from `self.sync_`{`blocks`,`all`} (Kittywhiskers Van Gogh)
3dcd87506e merge bitcoin#23207: Delete generate* calls from TestNode (Kittywhiskers Van Gogh)
7d3c3b4b64 merge bitcoin#22788: Use generate* from TestFramework (Kittywhiskers Van Gogh)
c17fd8bc59 merge bitcoin#22741: Add generate* calls to test framework (Kittywhiskers Van Gogh)
9938f4438d partial bitcoin#22550: improve `test_signing_with_{csv,cltv}` subtests (Kittywhiskers Van Gogh)
Pull request description:
## Additional Information
* [bitcoin#23207](https://github.com/bitcoin/bitcoin/pull/23207) has been marked partial as `test/functional/wallet_transactiontime_rescan.py` has not been backported yet.
* [bitcoin#22550](https://github.com/bitcoin/bitcoin/pull/22550) has been partially backported to track changes to `generate_to_height()` made in successive backports.
* <table>
<tr>
<td>
`develop` ([`5a0479fe`](5a0479fe53), [build](https://gitlab.com/dashpay/dash/-/jobs/7968420284#L640))
</td>
<td>
`dash#6288` ([`ecb51351`](ecb51351d1), [build](https://gitlab.com/dashpay/dash/-/jobs/7968651474#L612))
</td>
</tr>
<tr>
<td>
```
Running Unit Tests for Test Framework Modules
----------------------------------------------------------------------
Ran 18 tests in 32.370s
OK
1/266 - wallet_hd.py --legacy-wallet passed, Duration: 12 s
[...]
feature_bind_port_discover.py | ○ Skipped | 1 s
feature_bind_port_externalip.py | ○ Skipped | 1 s
interface_usdt_net.py | ○ Skipped | 1 s
interface_usdt_utxocache.py | ○ Skipped | 1 s
interface_usdt_validation.py | ○ Skipped | 1 s
rpc_bind.py --ipv6 | ○ Skipped | 1 s
ALL | ✓ Passed | 6961 s (accumulated)
Runtime: 1779 s
```
</td>
<td>
```
Running Unit Tests for Test Framework Modules
----------------------------------------------------------------------
Ran 18 tests in 32.318s
OK
1/266 - wallet_hd.py --legacy-wallet passed, Duration: 19 s
[...]
feature_bind_port_discover.py | ○ Skipped | 1 s
feature_bind_port_externalip.py | ○ Skipped | 1 s
interface_usdt_net.py | ○ Skipped | 1 s
interface_usdt_utxocache.py | ○ Skipped | 1 s
interface_usdt_validation.py | ○ Skipped | 1 s
rpc_bind.py --ipv6 | ○ Skipped | 1 s
ALL | ✓ Passed | 7048 s (accumulated)
Runtime: 1825 s
```
</td>
</tr>
</table>
## Breaking Changes
None expected.
## Checklist
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas **(note: N/A)**
- [x] I have added or updated relevant unit/integration/functional/e2e tests
- [x] I have made corresponding changes to the documentation **(note: N/A)**
- [x] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
PastaPastaPasta:
utACK 131d16133c656adc66717bfc819c5751d59a7f6c; no diff rebase, going to merge
Tree-SHA512: 369c826dae31a5fb605657146394b053f8eeef6051c328be4e44ea31b5fd17d8dfdc4c2772d220be03d7932c3f85d559ac7897be594dbbc9e7e1ce76f52376d4
Due to stricter checks, we can no longer start masternodes in parallel,
as entities used to process `to_connection` checks are reused before the
previous check is completed, resulting in an exception. Since we're
now validating the establishment of a two-way connection, we have to do
it one at a time.
9a9d0d5b79 feat: drop SPORK 24 (EHF) so far as this feature works on testnet / mainnet (Konstantin Akimov)
da0dc06eea perf: optimize feature_mnehf.py by generating less blocks (Konstantin Akimov)
0de3923b06 feat: bury fork mn_rr (masternode reward reallocation) (Konstantin Akimov)
Pull request description:
## Issue being fixed or feature implemented
MN_RR is activated on mainnet: time to bury it!
## What was done?
Hard-fork mn_rr is buried. Prior fixes are done here: https://github.com/dashpay/dash/pull/6270 and https://github.com/dashpay/dash/pull/6269
## How Has This Been Tested?
Run unit and functional tests
## Breaking Changes
N/A
## Checklist:
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [x] I have added or updated relevant unit/integration/functional/e2e tests
- [x] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone
ACKs for top commit:
UdjinM6:
light ACK 9a9d0d5b79
PastaPastaPasta:
utACK 9a9d0d5b79
Tree-SHA512: 73ea0ca1270f15f6f1193efbaf402d476c84e9a843af85b7eae3e40199f4c943ad40f58e062b8db20e1c5c69c1a85579ebaf0722f1044ee2e1a4e7f96c58e645
40f2ab906c test: don't attempt to reconnect already connected nodes (Kittywhiskers Van Gogh)
4a0fc8b69e test: don't attempt to (dis)connect nodes to/from themselves (Kittywhiskers Van Gogh)
Pull request description:
## Additional Information
* Dependency for https://github.com/dashpay/dash/pull/6276
## Checklist:
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [x] I have added or updated relevant unit/integration/functional/e2e tests
- [x] I have made corresponding changes to the documentation **(note: N/A)**
- [x] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_
ACKs for top commit:
UdjinM6:
utACK 40f2ab906c
Tree-SHA512: aaaeedabeb6b8ef77187fc14db1888c39863daf66afda93b8c8bc1dbbdf3ff6734445fd296d5b1034da6104e2d7cfcacf26b97b7be0a697b7a99f3671b6cb9a2
1e17b74207 test: no longer connect nodes in parallel in `start_masternodes` (UdjinM6)
be72ef5592 test: use `setmnthreadactive` to get controlable `connect_nodes` behaviour (UdjinM6)
e2ed82a7ae feat(rpc): introduce `setmnthreadactive` (regtest-only) (UdjinM6)
Pull request description:
## Issue being fixed or feature implemented
This adds a new rpc command to enable/disable automatic masternode connections creation. We need this for #6276. 1e17b74207 is extracted from ede1833ba4 to avoid multiple jobs calling `setmnthreadactive` on the same node in parallel.
## What was done?
Add `setmnthreadactive` rpc and use it
## How Has This Been Tested?
run tests
## Breaking Changes
n/a
## Checklist:
- [x] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have added or updated relevant unit/integration/functional/e2e tests
- [ ] I have made corresponding changes to the documentation
- [x] I have assigned this pull request to a milestone
ACKs for top commit:
kwvg:
LGTM, ACK 1e17b74207
PastaPastaPasta:
utACK 1e17b74207
Tree-SHA512: 83c1c07d0066e26202fd21942a09e41c3560c4d32229b44390946c4acb22319b32aa61a13b9106d20fc8cc197dd2a8ab5fdfcfdeaf3da76af062fc0fd7646972
It significantly improve speed of forks activation because reduces overhead for block generations
Bigger batch size can cause time-outs for RPC for tsan job (time-out is 30 seconds)
faa137eb9eac5554504b062a6dc865ca87fd572b test: Speed up rpc_blockchain.py by removing miniwallet.generate() (MarcoFalke)
fa1fe80c757df0adcbfaf41b5c5c8a468bc07b6f test: Change address type from P2PKH to P2WSH in rpc_blockchain (MarcoFalke)
fa4d8f3169e38cbdbae20258efebe7070c49f522 test: Cache 25 mature coins for ADDRESS_BCRT1_P2WSH_OP_TRUE (MarcoFalke)
fad25153f5c8e88f72cf666b16b0b0dbdc45d3b1 test: Remove unused bug workaround (MarcoFalke)
faabce7d07c5776e4116b1a7ad1f6c408a4a4e46 test: Start only the number of nodes that are needed (MarcoFalke)
Pull request description:
Speed up various tests:
* Remove unused nodes, which only consume time on start/stop
* Remove unused "bug workarounds"
* Remove the need for `miniwallet.generate()` by adding `miniwallet.scan_blocks()`. (On my system, with valgrind, generating 105 blocks takes 3.31 seconds. Rescanning 5 blocks takes 0.11 seconds.)
ACKs for top commit:
laanwj:
Code review ACK faa137eb9eac5554504b062a6dc865ca87fd572b
Tree-SHA512: ead1988d5aaa748ef9f8520af1e0bf812cf1d72e281ad22fbd172b7306d850053040526f8adbcec0b9a971c697a0ee7ee8962684644d65b791663eedd505a025