aboutsummaryrefslogtreecommitdiff
path: root/test
AgeCommit message (Collapse)Author
2021-05-03fuzz: Add -fsanitize=integer suppression needed for RPC fuzzerpracticalswift
2021-05-03Merge bitcoin/bitcoin#20867: Support up to 20 keys for multisig under Segwit ↵fanquake
context ebd4be43cc945e643f91d3a91007b5a35bbbd5a1 doc: add release notes for 20867 (Antoine Poinsot) 5aa50ab9cc7994b16cf13e4c73af80f0098f1bea rpc/util: multisig: only check redeemScript size is <= 520 for P2SH (Antoine Poinsot) 063df9e89730fd2c92646577e2fab894e1692130 test/functional: standardness sanity checks for P2(W)SH multisig (Antoine Poinsot) ae0429d3af6de48f6191f144dff4ad4ab672dcd6 script: allow up to 20 keys in wsh() descriptors (Antoine Poinsot) 9fc68faf35c700ae955af194dd7f8c1aee85a05b script: match multisigs with up to MAX_PUBKEYS_PER_MULTISIG keys (Antoine Poinsot) Pull request description: As described in https://github.com/bitcoin/bitcoin/issues/20620 multisigs are currently limited to 16 keys in descriptors and RPC helpers, even for P2WSH and P2SH-P2WSH. This adds support for multisig with up to 20 keys (which are already standard) for Segwit v0 context for descriptors (`wsh()`, `sh(wsh())`) and RPC helpers. Fixes https://github.com/bitcoin/bitcoin/issues/20620 ACKs for top commit: meshcollider: re-utACK ebd4be43cc945e643f91d3a91007b5a35bbbd5a1 instagibbs: re-ACK https://github.com/bitcoin/bitcoin/pull/20867/commits/ebd4be43cc945e643f91d3a91007b5a35bbbd5a1 Tree-SHA512: 36141f10a8288010d17d5c4fe8d24878bcd4533b88a8aba3a44fa8f74ceb3182d70fee01427e0ab7f53ce7fab46c88c1cd3ac3b18ab8a10bd4a6b8b74ed79e46
2021-05-02Merge bitcoin/bitcoin#21818: doc: fixup -coinstatsindex help, update ↵fanquake
bitcoin.conf and files.md 54133c59b80ccac85eaebb0668cd2f0fe360b323 doc: add indexes/coinstats/db/ to files.md (Jon Atack) 5d1050f51647980b1204e3b44b319ab31948d11f doc: fix -coinstatsindex help, and test/rpc touchups (Jon Atack) e041ee0a80e5f3e10301acf8512a18864af750cd doc: add coinstatsindex to bitcoin.conf (Jon Atack) Pull request description: ACKs for top commit: Sjors: utACK 54133c59b80ccac85eaebb0668cd2f0fe360b323 MarcoFalke: cr ACK 54133c59b80ccac85eaebb0668cd2f0fe360b323 clarkmoody: utACK 54133c5 Tree-SHA512: 1a7f3e89873b7dc79ec71d5d39e9e3e4977ce43cc4bee208ad55291bef1bb319a9d1c34ed84a87d6a803db983bdfd0af4d9f396cec0bec86b1701ebbb6f34378
2021-05-01doc: fix -coinstatsindex help, and test/rpc touchupsJon Atack
2021-05-01Merge bitcoin/bitcoin#21822: test: resolve bug in interface_bitcoin_cli.pyMarcoFalke
c5bb142817c53c6a217163958b5d511f12171004 test: resolve bug in test/functional/interface_bitcoin_cli.py - Test -getinfo with -rpcwallet=unloaded wallet returns no balances (klementtan) Pull request description: I think there is a bug in this test case where the new value of `cli_get_info` is not asserted. ACKs for top commit: jonatack: ACK c5bb142817c53c6a217163958b5d511f12171004 Tree-SHA512: 50c0c2c8fe63c95f951dee892fbacedf92208f47efe5ed481fbb255f15137c799d9200fa3ff31a442df0691248d7ff04d899842722c3032cd7f35553622ba38c
2021-05-01test: resolve bug in test/functional/interface_bitcoin_cli.py - Test ↵klementtan
-getinfo with -rpcwallet=unloaded wallet returns no balances
2021-04-30Merge bitcoin/bitcoin#19521: Coinstats IndexW. J. van der Laan
5f96d7d22d8e05876c6fc014e70488699950fe38 rpc: gettxoutsetinfo rejects hash_serialized_2 for specific height (Fabian Jahr) 23fe50436be641d7417152adc683192649ba206a test: Add test for coinstatsindex behavior in reorgs (Fabian Jahr) 90c966b0f3cfbd6bce5883f46d8527c6853a86a2 rpc: Allow gettxoutsetinfo and getblockstats for stale blocks (Fabian Jahr) b9362392aef2689bc106c20925859ede555d082b index, rpc: Add use_index option for gettxoutsetinfo (Fabian Jahr) bb7788b121a30489bc81a1f46dde6a9b19ae4ec1 test: Test coinstatsindex robustness across restarts (Fabian Jahr) e0938c29099635150014ffc9bb0cafa8049ec55a test: Add tests for block_info in gettxoutsetinfo (Fabian Jahr) 2501576eccb08af80471c7b7b843b189ad6758c0 rpc, index: Add verbose amounts tracking to Coinstats index (Fabian Jahr) 655d929836a71af23d2035d2e2e99ad8b8c340c3 test: add coinstatsindex getindexinfo coverage, improve current tests (Jon Atack) ca01bb8d689f93e1c7669b0ba7a4994c0206dabd rpc: Add Coinstats index to getindexinfo (Fabian Jahr) 57a026c30fef3138bb8db46e6865acb9dc2674f8 test: Add unit test for Coinstats index (Fabian Jahr) 6a4c0c09ab4d073a26c3c4a02783d5dcd88f6eef test: Add functional test for Coinstats index (Fabian Jahr) 3f166ecc125fce6ccd995687fa16572090a5d099 rpc: gettxoutsetinfo can be requested for specific blockheights (Fabian Jahr) 3c914d58ff323255b32e717d0ce28209ec0abdaa index: Coinstats index can be activated with command line flag (Fabian Jahr) dd58a4de21469d6d848ae309edc47f558628221d index: Add Coinstats index (Fabian Jahr) a8a46c4b3cfda4b95c92a36f8cebd3606377e57d refactor: Simplify ApplyStats and ApplyHash (Fabian Jahr) 9c8a265fd21a87228c18a1661df99fedc1866baf refactor: Pass hash_type to CoinsStats in stats object (Fabian Jahr) 2e2648a9021dfbb6e17dfa81472f057dacbc34e0 crypto: Make MuHash Remove method efficient (Fabian Jahr) Pull request description: This is part of the coinstats index project tracked in #18000 While the review of the new UTXO set hash algorithm (MuHash) takes longer recently #19328 was merged which added the possibility to run `gettxoutsetinfo` with a specific hash type. As the first type it added `hash_type=none` which skips the hashing of the UTXO set altogether. This alone did not make `gettxoutsetinfo` much faster but it allows the use of an index for the remaining coin statistics even before a new hashing algorithm has been added. Credit to Sjors for the idea to take this intermediate step. Features summary: - Users can start their node with the option `-coinstatsindex` which syncs the index in the background - After the index is synced the user can use `gettxoutsetinfo` with `hash_type=none` or `hash_type=muhash` and will get the response instantly out of the index - The user can specify a height or block hash when calling `gettxoutsetinfo` to see coin statistics at a specific block height ACKs for top commit: Sjors: re-tACK 5f96d7d22d8e05876c6fc014e70488699950fe38 jonatack: Code review re-ACK 5f96d7d22d8e05876c6fc014e70488699950fe38 per `git range-diff 13d27b4 07201d3 5f96d7d` promag: Tested ACK 5f96d7d22d8e05876c6fc014e70488699950fe38. Light code review ACK 5f96d7d22d8e05876c6fc014e70488699950fe38. Tree-SHA512: cbca78bee8e9605c19da4fbcd184625fb280200718396c694a56c7daab6f44ad23ca9fb5456d09f245d8b8d9659fdc2b3f3ce5e953c1c6cf4003dbc74c0463c2
2021-04-29test: Assert that exit code indicates failureMarcoFalke
2021-04-29test: Fix intermittent issue in p2p_segwit.pyMarcoFalke
2021-04-29Merge bitcoin/bitcoin#21804: [tests] Speed up p2p_segwit.pyMarcoFalke
a33bdb52d192d3e1f4697c98d0e80b2fa2bbe53a [tests] Speed up p2p_segwit.py (John Newbery) Pull request description: Never sleep for more than 5 seconds when waiting for an inv-getdata exchange to time out. Shaves about 1 minute of the runtime of p2p_segwit.py. ACKs for top commit: MarcoFalke: review ACK a33bdb52d192d3e1f4697c98d0e80b2fa2bbe53a 🐳 Tree-SHA512: 7bd892ed0b1b817579f88910ba4714519bd0d871241e1b9a67968d297de1ed63d558115abad2aae4d105ff176c35a7079a3a789f3053442aed30d6e1aefb5c4a
2021-04-29Merge bitcoin/bitcoin#21738: test: Use clang-12 for ASAN, Add missing ↵fanquake
suppression fa00bb2c5ca64c7eb9e1846ffedc7829859812ca test: Add missing shift-base:nanobench.h suppression (MarcoFalke) 00004565ccdbaf6bf337e10a5f5ae463bd0ccf9a ci: Use clang-12 for asan task (MarcoFalke) Pull request description: ACKs for top commit: fanquake: ACK fa00bb2c5ca64c7eb9e1846ffedc7829859812ca Tree-SHA512: fe7cd1ad9f3e73c09f7f84dfb0f276d0cda603c4d591b9338a0914bf1276b0247fd2faee7052f5962c3ae3280e7fa8b72f5b773b84c2a8882a89ed1f8c08256c
2021-04-29[tests] Speed up p2p_segwit.pyJohn Newbery
Never sleep for more than 5 seconds when waiting for an inv-getdata exchange to time out.
2021-04-29Merge bitcoin/bitcoin#21762: test: Speed up mempool_spend_coinbase.pyMarcoFalke
fa40eb5b6bfd151912c58d61771f6a6528f44e67 test: Speed up mempool_spend_coinbase.py (MarcoFalke) fa29382ab23d52b86bfda8a267195b6c51b713c2 test: Fix test cache issue (MarcoFalke) fa085b470a9647f3b261f506b46f4e7ca2baf0b0 test: Create MiniWallet.create_self_transfer (MarcoFalke) fa1bedb4944b513a3c9184ad549f58bfbe69e20e test: Add MiniWallet.sendrawtransaction (MarcoFalke) Pull request description: Locally the test will run 4 seconds faster with `--valgrind` (18s vs 14s) ACKs for top commit: mjdietzx: crACK https://github.com/bitcoin/bitcoin/pull/21762/commits/fa40eb5b6bfd151912c58d61771f6a6528f44e67 Tree-SHA512: ecfb60dda5ca5d7e6367bb9c6210390d95ebf6396ce657728901d118b75bb90c98f9351df3b01004d00682234448d6c6a13338d12097f7dced2cf7f1bd84d924
2021-04-29Merge bitcoin/bitcoin#21785: test: Fix intermittent issue in p2p_addr_relay.pyfanquake
faa51ef4d33034f8c14cfd18f1c01c90883a1bb4 test: Fix intermittent issue in p2p_addr_relay.py (MarcoFalke) fa37116c820f6a84642d57ce709a5977fd5616c4 test: Use self.send_addr_msg (MarcoFalke) Pull request description: Fixes https://github.com/bitcoin/bitcoin/pull/21707/files#r621048952 ACKs for top commit: mzumsande: ACK faa51ef4d33034f8c14cfd18f1c01c90883a1bb4 amitiuttarwar: ACK faa51ef4d33034f8c14cfd18f1c01c90883a1bb4 Tree-SHA512: b1fbc1a4a13b020890b465083a82762981de17dd710388c651353aefc28dee23d39803c2a1dadbf88287e92598901afcb01b488115b0fecd746ab6d73775415b
2021-04-28test/functional: standardness sanity checks for P2(W)SH multisigAntoine Poinsot
Note that it also test for sortedmulti(), which the previous commit didn't. Signed-off-by: Antoine Poinsot <darosior@protonmail.com>
2021-04-28test: Fix intermittent issue in p2p_addr_relay.pyMarcoFalke
2021-04-28test: Use self.send_addr_msgMarcoFalke
2021-04-27Merge bitcoin/bitcoin#19160: multiprocess: Add basic spawn and IPC supportW. J. van der Laan
84934bf70e11fe4cda1cfda60113a54895d4fdd5 multiprocess: Add echoipc RPC method and test (Russell Yanofsky) 7d76cf667eff512043a28d4407cc89f58796c42b multiprocess: Add comments and documentation (Russell Yanofsky) ddf7ecc8dfc64cf121099fb047e1ac871de94f4c multiprocess: Add bitcoin-node process spawning support (Russell Yanofsky) 10afdf0280fa93bfffb0a7665c60dc155cd84514 multiprocess: Add Ipc interface implementation (Russell Yanofsky) 745c9cebd50fea1664efef571dc1ee1bddc96102 multiprocess: Add Ipc and Init interface definitions (Russell Yanofsky) 5d62d7f6cd48bbc4e9f37ecc369f38d5e1e0036c Update libmultiprocess library (Russell Yanofsky) Pull request description: This PR is part of the [process separation project](https://github.com/bitcoin/bitcoin/projects/10). --- This PR adds basic process spawning and IPC method call support to `bitcoin-node` executables built with `--enable-multiprocess`[*]. These changes are used in https://github.com/bitcoin/bitcoin/pull/10102 to let node, gui, and wallet functionality run in different processes, and extended in https://github.com/bitcoin/bitcoin/pull/19460 and https://github.com/bitcoin/bitcoin/pull/19461 after that to allow gui and wallet processes to be started and stopped independently and connect to the node over a socket. These changes can also be used to implement new functionality outside the `bitcoin-node` process like external indexes or pluggable transports (https://github.com/bitcoin/bitcoin/pull/18988). The `Ipc::spawnProcess` and `Ipc::serveProcess` methods added here are entry points for spawning a child process and serving a parent process, and being able to make bidirectional, multithreaded method calls between the processes. A simple example of this is implemented in commit "Add echoipc RPC method and test." Changes in this PR aside from the echo test were originally part of #10102, but have been split and moved here for easier review, and so they can be used for other applications like external plugins. Additional notes about this PR can be found at https://bitcoincore.reviews/19160 [*] Note: the `--enable-multiprocess` feature is still experimental, and not enabled by default, and not yet supported on windows. More information can be found in [doc/multiprocess.md](https://github.com/bitcoin/bitcoin/blob/master/doc/multiprocess.md) ACKs for top commit: fjahr: re-ACK 84934bf70e11fe4cda1cfda60113a54895d4fdd5 ariard: ACK 84934bf. Changes since last ACK fixes the silent merge conflict about `EnsureAnyNodeContext()`. Rebuilt and checked again debug command `echoipc`. Tree-SHA512: 52a948b5e18a26d7d7a09b83003eaae9b1ed2981978c36c959fe9a55abf70ae6a627c4ff913a3428be17400a3dace30c58b5057fa75c319662c3be98f19810c6
2021-04-27Merge bitcoin/bitcoin#21009: Remove RewindBlockIndex logicW. J. van der Laan
d831e711cab83c70bf2ded62fe33f484844e73dd [validation] RewindBlockIndex no longer needed (Dhruv Mehta) Pull request description: Closes #17862 Context from [original comment](https://github.com/bitcoin/bitcoin/issues/17862#issuecomment-744285188) (minor edits): `RewindBlockIndex()` is a mechanism to allow nodes to be upgraded after segwit activation, while still keeping their chainstate/datadir in a consistent state. It works as follows: - A pre-segwit (i.e. v0.13.0 or older) node is running. - Segwit activates. The pre-segwit node remains sync'ed to the tip, but is not enforcing the new segwit rules. - The user upgrades the node to a segwit-aware version (v0.13.1 or newer). - On startup, in `AppInitMain()`, `RewindBlockIndex()` is called. This walks the chain backwards from the tip, disconnecting and erasing blocks that from after segwit activation that weren't validated with segwit rules. - those blocks are then redownloaded (with witness data) and validated with segwit rules. This logic probably isn't required any more since: - Segwit activated at height 481824, when the block chain was 130GB and the total number of txs was 250 million. Today, we're at height 667704, the blockchain is over 315GB and the total number of txs is over 600 million. Even if 20% of that added data is witness data (a high estimate), then around 150GB of transactions would need to be rewound to get back to segwit activation height. It'd probably be faster to simply validate from genesis, especially since we won't be validating any scripts before the assumevalid block. It's also unclear whether rewinding 150GB of transactions would even work. It's certainly never been tested. - Bitcoin Core v0.13 is hardly used any more. https://luke.dashjr.org/programs/bitcoin/files/charts/software.html shows less than 50 nodes running it. The software was EOL on Aug 1st 2018. It's very unlikely that anyone is running 0.13 and will want to upgrade to 0.22. This PR introduces `NeedsRedownload()` which merely checks for insufficiently validated segwit blocks and requests that the user restarts the node with `-reindex`. Reindexing the block files upon restart will make the node rebuild chain state and block index from the `blk*.dat` files on disk. The node won't be able to index the blocks with `BLOCK_OPT_WITNESS`, so they will be missing from the chain and be re-downloaded, with witness data. Removing this code allows the following (done in follow-up #21090): - removal of tests using `segwitheight=-1` in `p2p_segwit.py`. - in turn, that allows us to drop support for `-segwitheight=-1`, which is only supported for that test. - that allows us to always set `NODE_WITNESS` in our local services. The only reason we don't do that is to support `-segwitheight=-1`. - that in turn allows us to drop all of the `GetLocalServices() & NODE_WITNESS` checks inside `net_processing.cpp`, since our local services would always include `NODE_WITNESS` ACKs for top commit: jnewbery: utACK d831e711cab83c70bf2ded62fe33f484844e73dd jamesob: ACK https://github.com/bitcoin/bitcoin/pull/21009/commits/d831e711cab83c70bf2ded62fe33f484844e73dd laanwj: Cursory code review ACK d831e711cab83c70bf2ded62fe33f484844e73dd. Agree with the direction of the change, thanks for simplifying the logic here. glozow: utACK d831e711cab83c70bf2ded62fe33f484844e73dd Tree-SHA512: 3eddf5121ccd081ad7f15a5c6478ef867083edc8ba0bf1ee759e87bc070ee3d2f0698a3feba8db8dc087987c8452887b6f72cff05b3e178f41cb10a515fb8053
2021-04-26Merge bitcoin/bitcoin#21777: test: Fix feature_notifications.py intermittent ↵MarcoFalke
issue fa4aec2b26696cc16dc44c6425f7dca3ef91c8ee test: Fix feature_notifications.py intermittent issue (MarcoFalke) Pull request description: Fixes #21683 Top commit has no ACKs. Tree-SHA512: 256806d82877477f4b3d795658f61127c0de4eff07216f6071f40a8ec1f5d43f3c587f35dd436d480dc261ef6646ac5547db104d22f3fcfeeb61bbdbe04bcc31
2021-04-26Merge bitcoin/bitcoin#21707: test: Extend functional tests for addr relayMarcoFalke
a732ee353c1922a1f9ca082775884d190893e0e9 [test] Add tests for addr relay in -blocksonly mode (Amiti Uttarwar) a6694eaed8f86a6ad79689bbcbfdbed4d73327c9 [test] Add address relay tests involving outbound peers (Martin Zumsande) 8188b77c17d78bf608cb41978db4d0f46e91f7d8 [test] Add tests for getaddr behavior (Martin Zumsande) d2dbfe6ff1806e5248399b28a7a1a22dab726c40 [test] Extract sending an addr message into a helper (Amiti Uttarwar) c9919433994924931757aa7ec278c50744ede35d [test] Refactor the addr relay test to prepare for new tests (Amiti Uttarwar) Pull request description: This extends the functional test `p2p_addr_relay.py`. It adds test coverage for address relay involving outbound peers, tests for both outgoing and incoming `GETADDR` requests and tests for `-blocksonly` mode. The initial refactors and some of the new tests were taken from Amiti Uttarwar's PR #21528 - they are general test improvements not directly tied to the change proposed there. ACKs for top commit: amitiuttarwar: re-ACK a732ee353c, small diff based on code review MarcoFalke: Concept ACK a732ee353c1922a1f9ca082775884d190893e0e9 🌊 Tree-SHA512: e80d52683808ddd6b948a5134239f002f3fecf61b60e187877b07be6251721fde847104e495c75a1a5133a09c0b41a9255a0bec82932c0b304b516fa89bce33e
2021-04-26test: Fix feature_notifications.py intermittent issueMarcoFalke
2021-04-23multiprocess: Add echoipc RPC method and testRussell Yanofsky
Add simple interfaces::Echo IPC interface with one method that just takes and returns a string, to test multiprocess framework and provide an example of how it can be used to spawn and call between processes.
2021-04-23multiprocess: Add Ipc interface implementationRussell Yanofsky
2021-04-23test: Speed up mempool_spend_coinbase.pyMarcoFalke
2021-04-23test: Fix test cache issueMarcoFalke
The documentation did not match the implementation, no coins were mined to the OP_TRUE address.
2021-04-23test: Create MiniWallet.create_self_transferMarcoFalke
2021-04-22test: Add MiniWallet.sendrawtransactionMarcoFalke
Can be reviewed with --ignore-all-space --color-moved=dimmed-zebra
2021-04-22Merge bitcoin/bitcoin#19801: test: check for all possible OP_CLTV fail ↵MarcoFalke
reasons in feature_cltv.py (BIP 65) b01cd9471f435bb36b8ed5211a56baad51111ad2 test: check that _all_ invalid-CLTV txs are rejected after BIP65 activation (Sebastian Falbesoner) dbc19814743cb12960a99793197c811e2750a06b test: check that _all_ invalid-CLTV txs are allowed in a block pre-BIP65 (Sebastian Falbesoner) 8d0ce50c4826529a2d30ffc850bce4d44da6019b test: prepare cltv_invalidate to test all failure reasons in feature_cltv.py (Sebastian Falbesoner) ce994e1202c4820b1ad5c375d3d671fd0a18e092 test: add tx modfication helper function in feature_cltv.py (Sebastian Falbesoner) Pull request description: The functional test for [BIP65](https://github.com/bitcoin/bips/blob/master/bip-0065.mediawiki) / `OP_CHECKLOCKTIMEVERIFY` (`feature_cltv.py`) currently only tests one out of five conditions that lead to failure of the op-code -- by prepending the script `OP_1NEGATE OP_CHECKLOCKTIMEVERIFY OP_DROP` to a tx's first input's scriptSig, the case of "_the top item on the stack is less than 0_" is checked: https://github.com/bitcoin/bitcoin/blob/f8462a6d2794be728cf8550f45d19a354aae59cf/test/functional/feature_cltv.py#L26-L35 This PR adds the other cases (5 in total) by taking an integer argument to the function `cltv_invalidate` that is called in a loop instead of only once per testing scenario. Here is the full list of failure conditions and how they are tested (note that the scriptSig should still be valid before activation of BIP65, when `OP_CLTV` is simply a no-op): * _the stack is empty_ ➡️ prepending `OP_CHECKLOCKTIMEVERIFY` to scriptSig * _the top item on the stack is less than 0_ ➡️ prepending `OP_1NEGATE OP_CHECKLOCKTIMEVERIFY OP_DROP` to scriptSig * _the lock-time type (height vs. timestamp) of the top stack item and the nLockTime field are not the same_ ➡️ prepending `OPNum(1000) OP_CHECKLOCKTIMEVERIFY OP_DROP` to scriptSig ➡️ setting tx.vin[0].nSequence=0 and tx.nCheckTimeLock=1296688602 (genesis block timestamp) * _the top stack item is greater than the transaction's nLockTime field_ ➡️ prepending `OPNum(1000) OP_CHECKLOCKTIMEVERIFY OP_DROP` to scriptSig ➡️ setting tx.vin[0].nSequence=0 and tx.nCheckTimeLock=500 * _the nSequence field of the txin is 0xffffffff_ ➡️ prepending `OPNum(500) OP_CHECKLOCKTIMEVERIFY OP_DROP` to scriptSig ➡️ setting tx.vin[0].nSequence=0xffffffff and tx.nCheckTimeLock=500 The first commit creates a helper function for the tx modification and also includes some tidying up like turning single-line to multi-line Python imports where necessary and cleaning up some PEP8 warnings. The second commit prepares the invalidation function `cltv_invalidate` and the third and the fourth use it and check for the expected reject reason strings ("Operation not valid with the current stack size", "Negative locktime" and "Locktime requirement not satisfied"). ACKs for top commit: MarcoFalke: review ACK b01cd9471f435bb36b8ed5211a56baad51111ad2 🐣 Tree-SHA512: dd82ae86e2bc4f3ab9bb1cfc9f04e4431b2b59c8aaf2a9f4b28654a1577e003fb43c500f99d76ff57e96262168e1cad7c1a0d71158e4b01063737e8f4be1e07d
2021-04-21[validation] RewindBlockIndex no longer neededDhruv Mehta
Instead of rewinding blocks, we request that the user restarts with -reindex
2021-04-21[test] Add tests for addr relay in -blocksonly modeAmiti Uttarwar
Co-Authored-By: Martin Zumsande <mzumsande@gmail.com>
2021-04-21[test] Add address relay tests involving outbound peersMartin Zumsande
Co-authored-by: Amiti Uttarwar <amiti@uttarwar.org>
2021-04-21[test] Add tests for getaddr behaviorMartin Zumsande
Co-authored-by: Amiti Uttarwar <amiti@uttarwar.org>
2021-04-21[test] Extract sending an addr message into a helperAmiti Uttarwar
Also reduces mocktime to prevent idle disconnects Co-Authored-By: Martin Zumsande <mzumsande@gmail.com>
2021-04-21[test] Refactor the addr relay test to prepare for new testsAmiti Uttarwar
Moves setting up the addr message into a repeatable function, and breaks up the existing tests into separate functions for legibility.
2021-04-20test: Add missing shift-base:nanobench.h suppressionMarcoFalke
Otherwise it is not possible to run bench_bitcoin with clang-12 + ASAN compiled. Output: $ src/bench/bench_bitcoin bench/nanobench.h:1107:15: runtime error: left shift of 4982565676696827473 by 27 places cannot be represented in type 'uint64_t' (aka 'unsigned long') #0 0x5623d6a13137 in ankerl::nanobench::Rng::rotl(unsigned long, unsigned int) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/./bench/nanobench.h:1107:15 #1 0x5623d6a13137 in ankerl::nanobench::Rng::operator()() /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/./bench/nanobench.h:1075:10 #2 0x5623d6a05c5b in ankerl::nanobench::Rng::Rng(unsigned long) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/./bench/nanobench.h:3135:9 #3 0x5623d6a0ca51 in ankerl::nanobench::detail::IterationLogic::Impl::Impl(ankerl::nanobench::Bench const&) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/./bench/nanobench.h:2206:13 #4 0x5623d69f8f73 in ankerl::nanobench::detail::IterationLogic::IterationLogic(ankerl::nanobench::Bench const&) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/./bench/nanobench.h:2215:18 #5 0x5623d690f165 in ankerl::nanobench::Bench& ankerl::nanobench::Bench::run<AddrManAdd(ankerl::nanobench::Bench&)::$_0>(AddrManAdd(ankerl::nanobench::Bench&)::$_0&&) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/./bench/nanobench.h:1114:28 #6 0x5623d690e26e in AddrManAdd(ankerl::nanobench::Bench&) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/bench/addrman.cpp:76:11 #7 0x5623d69279d6 in void std::__invoke_impl<void, void (*&)(ankerl::nanobench::Bench&), ankerl::nanobench::Bench&>(std::__invoke_other, void (*&)(ankerl::nanobench::Bench&), ankerl::nanobench::Bench&) /usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/bits/invoke.h:60:14 #8 0x5623d6927921 in std::enable_if<is_invocable_r_v<void, void (*&)(ankerl::nanobench::Bench&), ankerl::nanobench::Bench&>, void>::type std::__invoke_r<void, void (*&)(ankerl::nanobench::Bench&), ankerl::nanobench::Bench&>(void (*&)(ankerl::nanobench::Bench&), ankerl::nanobench::Bench&) /usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/bits/invoke.h:110:2 #9 0x5623d692775f in std::_Function_handler<void (ankerl::nanobench::Bench&), void (*)(ankerl::nanobench::Bench&)>::_M_invoke(std::_Any_data const&, ankerl::nanobench::Bench&) /usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/bits/std_function.h:291:9 #10 0x5623d692dbd5 in std::function<void (ankerl::nanobench::Bench&)>::operator()(ankerl::nanobench::Bench&) const /usr/bin/../lib/gcc/x86_64-linux-gnu/10/../../../../include/c++/10/bits/std_function.h:622:14 #11 0x5623d692cd44 in benchmark::BenchRunner::RunAll(benchmark::Args const&) /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/bench/bench.cpp:65:13 #12 0x5623d69282bf in main /bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/bench/bench_bitcoin.cpp:63:5 #13 0x7f6812010564 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x28564) #14 0x5623d685f4dd in _start (/bitcoin/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/src/bench/bench_bitcoin+0x13754dd) SUMMARY: UndefinedBehaviorSanitizer: invalid-shift-base bench/nanobench.h:1107:15 in $ clang --version Ubuntu clang version 12.0.0-1ubuntu1 Target: x86_64-pc-linux-gnu Thread model: posix InstalledDir: /usr/bin
2021-04-19rpc: gettxoutsetinfo rejects hash_serialized_2 for specific heightFabian Jahr
2021-04-19test: Add test for coinstatsindex behavior in reorgsFabian Jahr
Co-authored-by: Sjors Provoost <sjors@sprovoost.nl>
2021-04-19index, rpc: Add use_index option for gettxoutsetinfoFabian Jahr
2021-04-19test: Test coinstatsindex robustness across restartsFabian Jahr
2021-04-19test: Add tests for block_info in gettxoutsetinfoFabian Jahr
This additional data will automatically be returned if the coinstats index is used.
2021-04-19rpc, index: Add verbose amounts tracking to Coinstats indexFabian Jahr
2021-04-19test: add coinstatsindex getindexinfo coverage, improve current testsJon Atack
2021-04-19test: Add functional test for Coinstats indexFabian Jahr
2021-04-19index: Coinstats index can be activated with command line flagFabian Jahr
2021-04-19Merge #20857: test: update documentation in feature_csv_activation.pyMarcoFalke
9053b88b1c15f57cdcff2fc1c761efebb2ebfefe update docstring in feature_csv_activation.py (Pierre K) Pull request description: These changes in the test documentation reflect the changes introduced in #17921. ACKs for top commit: MarcoFalke: review ACK 9053b88 Tree-SHA512: 17fb954baded8dab1c869dd48b76b516150bae616c792c573e4114d4adfdd40195745c56570aa3050cc0015ee496acd7ec178df8ba14831dd22f9722fda84da2
2021-04-18update docstring in feature_csv_activation.pyPierre K
These changes in the test documentation reflect the changes introduced in #17921
2021-04-18rpc: Improve getblock error message for invalid data type.klementtan
2021-04-16qa: Test default include_mempool value of gettxoutJoão Barbosa
2021-04-15Merge #21377: Speedy trial support for versionbitsfanquake
ffe33dfbd4c3b11e3475b022b6c1dd077613de79 chainparams: drop versionbits threshold to 90% for mainnnet and signet (Anthony Towns) f054f6bcd2c2ce5fea84cf8681013f85a444e7ea versionbits: simplify state transitions (Anthony Towns) 55ac5f568a3b73d6f1ef4654617fb76e8bcbccdf versionbits: Add explicit NEVER_ACTIVE deployments (Anthony Towns) dd07e6da48040dc7eae46bc7941db48d98a669fd fuzz: test versionbits delayed activation (Anthony Towns) dd85d5411c1702c8ae259610fe55050ba212e21e tests: test versionbits delayed activation (Anthony Towns) 73d4a706393e6dbd6b6d6b6428f8d3233ac0a2d8 versionbits: Add support for delayed activation (Anthony Towns) 9e6b65f6fa205eee5c3b99343988adcb8d320460 tests: clean up versionbits test (Anthony Towns) 593274445004506c921d5d851361aefb3434d744 tests: test ComputeBlockVersion for all deployments (Anthony Towns) 63879f0a4760c0c0f784029849cb5d21ee088abb tests: pull ComputeBlockVersion test into its own function (Anthony Towns) Pull request description: BIP9-based implementation of "speedy trial" activation specification, see https://lists.linuxfoundation.org/pipermail/bitcoin-dev/2021-March/018583.html Edge cases are tested by fuzzing added in #21380. ACKs for top commit: instagibbs: tACK https://github.com/bitcoin/bitcoin/pull/21377/commits/ffe33dfbd4c3b11e3475b022b6c1dd077613de79 jnewbery: utACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 MarcoFalke: review ACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 💈 achow101: re-ACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 gmaxwell: ACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 benthecarman: ACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 Sjors: ACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 jonatack: Initial approach ACK ffe33dfbd4c3b11e3475b022b6c1dd077613de79 after a first pass of review, building and testing each commit, mostly looking at the changes and diffs. Will do a more high-level review iteration. A few minor comments follow to pick/choose/ignore. ariard: Code Review ACK ffe33df Tree-SHA512: f79a7146b2450057ee92155cbbbcec12cd64334236d9239c6bd7d31b32eec145a9781c320f178da7b44ababdb8808b84d9d22a40e0851e229ba6d224e3be747c