aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2023-10-06chain: Rename HaveTxsDownloaded to HaveNumChainTxsFabian Jahr
Co-authored-by: MarcoFalke <falke.marco@gmail.com>
2023-10-06blockstorage: Let FlushChainstateBlockFile return true in case of missing cursorFabian Jahr
Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
2023-10-06validation, test: Improve and document nChainTx check for testabilityFabian Jahr
Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
2023-10-06doc: Add snapshot chainstate removal warning to reindexing documentationFabian Jahr
2023-10-06test: Improvements of feature_assumeutxoFabian Jahr
- Remove usage of the internal wait_until_helper function - Use framework self.no_op instead of new no_sync function co-authored-by: Andrew Chow <github@achow101.com>
2023-10-06doc: Add and edit some comments around assumeutxoFabian Jahr
Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
2023-10-06validation: remove unused mempool param in DetectSnapshotChainstateFabian Jahr
2023-10-06Merge bitcoin/bitcoin#28253: test: display abrupt shutdown errors in console ↵fanquake
output 0f83ab407ec5aa0591c54c03bcf408c7f2f0a192 test: display abrupt shutdown errors in console output (furszy) Pull request description: Making it easier to debug errors in the CI environment, particularly in scenarios where it's not immediately clear what happened nor which node crashed (or shutdown abruptly). A bit of context: Currently, the test framework redirects each node's stderr output stream to a different temporary file inside each node's data directory. While this is sufficient for storing the error, it isn't very helpful for understanding what happened just by reading the CI console output. Most of the time, reading the stderr file in the CI environment is not possible, because people don't have access to it. Testing Note: The displayed error difference can be observed by cherry-picking this commit https://github.com/furszy/bitcoin-core/commit/9cc5393c0f24c774b4a59706fc7c7873a59573e7 on top of this branch and running any functional test. ACKs for top commit: maflcko: lgtm ACK 0f83ab407ec5aa0591c54c03bcf408c7f2f0a192 theStack: ACK 0f83ab407ec5aa0591c54c03bcf408c7f2f0a192 Tree-SHA512: 83ce4d21d5316e8cb16a17d3fbe77b8649fced9e09410861d9674c233f6e9c34bcf573504e387e4f439c2841b2ee9855d0d35607fa13aa89eafe0080c45ee82d
2023-10-06Merge bitcoin/bitcoin#28532: qt: enable` -ltcg` for windows under LTOfanquake
f0cebbdb2a1a3c2f0facd88963484ad6fd5851db qt: enable -ltcg for windows HOST (fanquake) Pull request description: Patch around multiple definition issues in Qt, and enable `-ltcg` when using `LTO=1`. Split from #25391. ACKs for top commit: hebasto: ACK f0cebbdb2a1a3c2f0facd88963484ad6fd5851db Tree-SHA512: 2d6e34779f360bf6dfea4f70fc9004a16e95da79716fcb3046afbf2b01317b7e16965cb51b967b7b5fb64549306c5f48cf59082884289c52016bc1e86949e062
2023-10-05test: Use feerate higher than minrelay fee in wallet_fundrawAndrew Chow
The external input weight test in wallet_fundrawtransaction.py made transactions at the minimum relay fee. However due to ECDSA sometimes making a shorter signature than expected, the size estimate (and therefore the funded fee) ends up being a little bit too low, which results in the final transaction being under the min relay fee. We can compensate for this by just using a feerate higher than the minrelayfee as the actual feerate itself does not matter in this test.
2023-10-05Merge bitcoin/bitcoin#27609: rpc: allow submitpackage to be called outside ↵Andrew Chow
of regtest 5b878be742dbfcd232d949d2df1fff4743aec3d8 [doc] add release note for submitpackage (glozow) 7a9bb2a2a59ba49f80519c8435229abec2432486 [rpc] allow submitpackage to be called outside of regtest (glozow) 5b9087a9a7da2602485e85e0b163dc3cbd2daf31 [rpc] require package to be a tree in submitpackage (glozow) e32ba1599c599e75b1da3393f71f633de860505f [txpackages] IsChildWithParentsTree() (glozow) b4f28cc345ef9c5261c4a8d743654a44784c7802 [doc] parent pay for child in aggregate CheckFeeRate (glozow) Pull request description: Permit (restricted topology) submitpackage RPC outside of regtest. Suggested in https://github.com/bitcoin/bitcoin/pull/26933#issuecomment-1510851570 This RPC should be safe but still experimental - interface may change, not all features (e.g. package RBF) are implemented, etc. If a miner wants to expose this to people, they can effectively use "package relay" before the p2p changes are implemented. However, please note **this is not package relay**; transactions submitted this way will not relay to other nodes if the feerates are below their mempool min fee. Users should put this behind some kind of rate limit or permissions. ACKs for top commit: instagibbs: ACK 5b878be742dbfcd232d949d2df1fff4743aec3d8 achow101: ACK 5b878be742dbfcd232d949d2df1fff4743aec3d8 dergoegge: Code review ACK 5b878be742dbfcd232d949d2df1fff4743aec3d8 ajtowns: ACK 5b878be742dbfcd232d949d2df1fff4743aec3d8 ariard: Code Review ACK 5b878be742. Though didn’t manually test the PR. Tree-SHA512: 610365c0b2ffcccd55dedd1151879c82de1027e3319712bcb11d54f2467afaae4d05dca5f4b25f03354c80845fef538d3938b958174dda8b14c10670537a6524
2023-10-05Merge bitcoin/bitcoin#28597: wallet: No BDB creation, unless ↵Andrew Chow
-deprecatedrpc=create_bdb fa071aeb61dcc42cd122d3fb1abe4b9c238f8010 wallet: No BDB creation, unless -deprecatedrpc=create_bdb (MarcoFalke) Pull request description: With BDB being removed soon, it seems confusing and harmful to allow users to create fresh BDB wallets going forward, as it would load them with an additional burden of having to migrate them soon after. Also, it would be good to allow for one release for test (and external) scripts to adapt. Fix all issues by introducing the `-deprecatedrpc=create_bdb` setting. ACKs for top commit: Sjors: tACK fa071aeb61dcc42cd122d3fb1abe4b9c238f8010 achow101: ACK fa071aeb61dcc42cd122d3fb1abe4b9c238f8010 furszy: utACK fa071aeb Tree-SHA512: 37a4c3e4ba659e0ebe2382e71d9c80e42a895d9ad743f5dda7c110fbbb7d2a36f46769982552a9ac0c3a57203379ef164be97aa8033eb7674d6b4da030ba8f9b
2023-10-05Merge bitcoin/bitcoin#28590: assumeutxo: change getchainstates RPC to return ↵Andrew Chow
a list of chainstates a9ef702a877a964bac724a56e2c0b5bee4ea7586 assumeutxo: change getchainstates RPC to return a list of chainstates (Ryan Ofsky) Pull request description: Current `getchainstates` RPC returns "normal" and "snapshot" fields which are not ideal because it requires new "normal" and "snapshot" terms to be defined, and the definitions are not really consistent with internal code. (In the RPC interface, the "snapshot" chainstate becomes the "normal" chainstate after it is validated, while in internal code there is no "normal chainstate" and the "snapshot chainstate" is still called that temporarily after it is validated). The current `getchainstates` RPC is also awkward to use if you to want information about the most-work chainstate, because you have to look at the "snapshot" field if it exists, and otherwise fall back to the "normal" field. Fix these issues by having `getchainstates` just return a flat list of chainstates ordered by work, and adding a new chainstate "validated" field alongside the existing "snapshot_blockhash" field so it is explicit if a chainstate was originally loaded from a snapshot, and whether the snapshot has been validated. This change was motivated by comment thread in https://github.com/bitcoin/bitcoin/pull/28562#discussion_r1344154808 ACKs for top commit: Sjors: re-ACK a9ef702a877a964bac724a56e2c0b5bee4ea7586 jamesob: re-ACK a9ef702 achow101: ACK a9ef702a877a964bac724a56e2c0b5bee4ea7586 Tree-SHA512: b364e2e96675fb7beaaee60c4dff4b69e6bc2d8a30dea1ba094265633d1cddf9dbf1c5ce20c07d6e23222cf1e92a195acf6227e4901f3962e81a1e53a43490aa
2023-10-05Merge bitcoin/bitcoin#28587: descriptors: disallow hybrid public keysAndrew Chow
c1e6c542af6d89a499e2a65465865aec651c4d67 descriptors: disallow hybrid public keys (Pieter Wuille) Pull request description: Fixes #28511 The descriptor documentation (`doc/descriptors.md`) and [BIP380](https://github.com/bitcoin/bips/blob/master/bip-0380.mediawiki) explicitly require that hex-encoded public keys start with 02 or 03 (compressed) or 04 (uncompressed). However, the current parsing/inference code permit 06 and 07 (hybrid) encoding as well. Fix this. ACKs for top commit: darosior: ACK c1e6c542af6d89a499e2a65465865aec651c4d67 achow101: ACK c1e6c542af6d89a499e2a65465865aec651c4d67 Tree-SHA512: 23b674fb420619b2536d12da10008bb87cf7bc0333ec59e618c0d02c3574b468cc71248475ece37f76658d743ef51e68566948e903bca79fda5f7d75416fea4d
2023-10-05Merge bitcoin/bitcoin#28027: test: Fixes and updates to ↵fanquake
wallet_backwards_compatibility.py for 25.0 and descriptor wallets afd9a673c458e97305da49a70a1ddbf60e651876 test: roundtrip wallet backwards compat downgrade (Andrew Chow) bbf43c63b9472a79462e625a1f0592973c22b47c test: Add 25.0 to wallet backwards compatibiilty test (Andrew Chow) 538939ec39e146bedffb80cf84849a450ea8fead test: Run upgrade test on all nodes (Andrew Chow) 6d4699028b17cb33953f7d11764e06069dd58915 test: Run downgrade test on descriptor wallets (Andrew Chow) f158573be12746991b75587cc9e41a74a5e986eb test: Add 0.21 tr() incompatibility test (Andrew Chow) f41215c3f08f99d1bfa524f2da8055b6a4458bbb test: add logging 0.17 incompatibilities in wallet back compat (Andrew Chow) 71c03aeff7e1c63c21fa72d119311230f0b30e73 test: Refactor v19 addmultisigaddress test to be distinct (Andrew Chow) 53f35d02cb7b67ddecc9514559083f85093b6ce5 test: Remove w1_v18 from wallet backwards compatibility (Andrew Chow) 313d665437079ce8426916a41a11972e97c73d6d test: Fix 0.16 wallet paths and downgrade test (Andrew Chow) 5d8469362acfb7a03e0f767dbb7166830355bead test: Add helper functions for checking node versions (Andrew Chow) Pull request description: It was somewhat surprising to me that wallet_backwards_compatibility.py did not catch #27915 since the purpose of the test is to find downgrade issues such as that. It turns out the test was deficient in several places when it came to testing descriptor wallets, as well as deficient in addition to failing to correctly test some releases. This PR fixes these test cases, adds more informative logging, slightly refactors the entire test in order to better test future versions, and adds a 25.0 node to the test. Notable changes: * The compatibility test with 0.16 should not have been passing. The wallets were being copied incorrectly for 0.16 and resulting in 0.16 creating new wallets rather than testing the target wallets. * The downgrade test will actually be run on descriptor wallets and it will test that downgrades are successful, and a subsequent upgrade is also successful. This catches #27915. * The upgrade and downgrade test will be run on all versions up to master, rather than just 0.16, 0.17, and 0.19. ACKs for top commit: Sjors: re-ACK afd9a673c458e97305da49a70a1ddbf60e651876 furszy: ACK afd9a67 Tree-SHA512: dd2d85cab29a636da93020681c533534af4a9cda18d8550c9db9d8937719b3a225025966981c5d4d2f30486448a772b760f0e723a25ea6bc49df80387dc7b8b0
2023-10-05Merge bitcoin/bitcoin#28403: test: Bump walletpassphrase timeouts to avoid ↵Andrew Chow
intermittent issues fa28f5a3819a4bb69b046529e05932016273170b test: Bump walletpassphrase timeouts to avoid intermittent issues (MarcoFalke) Pull request description: This bumps all timeouts for all `walletpassphrase` to avoid intermittent issues in `valgrind` (or other sanitizers). As an idea for a follow-up, `walletpassphrase` could be changed to treat `0` as "no timeout" instead of "instant timeout". Example failure: ``` node0 2023-09-03T22:44:38.374955Z [httpworker.3] [rpc/server.cpp:594] [RPCRunLater] [rpc] queue run of timer lockwallet(w6) in 60 seconds (using HTTP) test 2023-09-03T22:44:40.173000Z TestFramework.bitcoincli (DEBUG): Running bitcoin-cli ['-rpcwallet=w6', 'getnewaddress', '', 'legacy'] node0 2023-09-03T22:44:59.810893Z [http] [httpserver.cpp:255] [http_request_cb] [http] Received a POST request for /wallet/w6 from 127.0.0.1:48928 node0 2023-09-03T22:44:59.813132Z [httpworker.1] [rpc/request.cpp:181] [parse] [rpc] ThreadRPCServer method=getnewaddress user=__cookie__ node0 2023-09-03T22:44:59.837183Z [httpworker.1] [wallet/sqlite.cpp:53] [TraceSqlCallback] [/ci_container_base/ci/scratch/test_runner/test_runner_₿_🏃_20230903_183350/wallet_createwallet_171/node0/regtest/w6/wallet.dat] SQLite Statement: INSERT or REPLACE into main values(?, ?) node0 2023-09-03T22:44:59.929735Z [httpworker.1] [wallet/sqlite.cpp:53] [TraceSqlCallback] [/ci_container_base/ci/scratch/test_runner/test_runner_₿_🏃_20230903_183350/wallet_createwallet_171/node0/regtest/w6/wallet.dat] SQLite Statement: INSERT or REPLACE into main values(?, ?) node0 2023-09-03T22:44:59.934484Z [httpworker.1] [wallet/sqlite.cpp:53] [TraceSqlCallback] [/ci_container_base/ci/scratch/test_runner/test_runner_₿_🏃_20230903_183350/wallet_createwallet_171/node0/regtest/w6/wallet.dat] SQLite Statement: INSERT or REPLACE into main values(?, ?) node0 2023-09-03T22:44:59.935467Z [httpworker.1] [wallet/sqlite.cpp:53] [TraceSqlCallback] [/ci_container_base/ci/scratch/test_runner/test_runner_₿_🏃_20230903_183350/wallet_createwallet_171/node0/regtest/w6/wallet.dat] SQLite Statement: INSERT or REPLACE into main values(?, ?) test 2023-09-03T22:45:02.328000Z TestFramework.bitcoincli (DEBUG): Running bitcoin-cli ['-rpcwallet=w6', 'signmessage', 'mqatqH4VQmrZ81nxUfrnfcLnxgbzhZb4PC', 'test'] node0 2023-09-03T22:45:20.269375Z [http] [httpserver.cpp:255] [http_request_cb] [http] Received a POST request for /wallet/w6 from 127.0.0.1:44618 node0 2023-09-03T22:45:20.270670Z [httpworker.2] [rpc/request.cpp:181] [parse] [rpc] ThreadRPCServer method=signmessage user=__cookie__ test 2023-09-03T22:45:23.490000Z TestFramework.bitcoincli (DEBUG): Running bitcoin-cli ['-rpcwallet=w6', 'keypoolrefill', '1'] node0 2023-09-03T22:45:40.244603Z [http] [httpserver.cpp:255] [http_request_cb] [http] Received a POST request for /wallet/w6 from 127.0.0.1:32854 node0 2023-09-03T22:45:40.293021Z [httpworker.0] [rpc/request.cpp:181] [parse] [rpc] ThreadRPCServer method=keypoolrefill user=__cookie__ test 2023-09-03T22:45:41.852000Z TestFramework (ERROR): JSONRPC error 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/wallet_createwallet.py", line 156, in run_test w6.keypoolrefill(1) File "/ci_container_base/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/test_node.py", line 732, in __call__ return self.cli.send_cli(self.command, *args, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/ci_container_base/ci/scratch/build/bitcoin-x86_64-pc-linux-gnu/test/functional/test_framework/test_node.py", line 795, in send_cli raise JSONRPCException(dict(code=int(code), message=message)) test_framework.authproxy.JSONRPCException: Error: Please enter the wallet passphrase with walletpassphrase first. (-13) ACKs for top commit: achow101: ACK fa28f5a3819a4bb69b046529e05932016273170b Tree-SHA512: 58caa569cec39acc121d4cc038a4190937af34e85d2696272ed4f2792fd386469b0cfefd2cb564438fedded97b21b23d8bf46ba27b5633671a277ed4679f0d5d
2023-10-05doc: update example pulls in release-process.mdfanquake
2023-10-05github actions: Fix test-one-commit when parent of head is merge commitRyan Ofsky
Instead of figuring out the commit *after* the last merge and rebasing on that with a ~1 suffix, just figure out the last merge commit directly and rebase on it. This way, if HEAD happens to be a merge commit, the rebase just succeeds immediately without blank variables or errors. From https://github.com/bitcoin/bitcoin/pull/28497#issuecomment-1743430631: The problem is that the PR only contains a one commit after the last merge, so the job _should_ be skipped, but the `pull_request.commits != 1` check is not smart enough to skip it because the PR is based on another PR and has merge ancestor commits. So specifically what happens is that after HEAD~ is checked out, the new HEAD is a merge commit, so the range `$(git log --merges -1 --format=%H)..HEAD` is equivalent to HEAD..HEAD, which is empty, so the `COMMIT_AFTER_LAST_MERGE` variable is empty and the rebase command fails.
2023-10-05wallet: No BDB creation, unless -deprecatedrpc=create_bdbMarcoFalke
2023-10-05assumeutxo: change getchainstates RPC to return a list of chainstatesRyan Ofsky
Current getchainstates RPC returns "normal" and "snapshot" fields which are not ideal because it requires new "normal" and "snapshot" terms to be defined, and the definitions are not really consistent with internal code. (In the RPC interface, the "snapshot" chainstate becomes the "normal" chainstate after it is validated, while in internal code there is no "normal chainstate" and the "snapshot chainstate" is still called that temporarily after it is validated). The current getchainstatees RPC is also awkward to use if you to want information about the most-work chainstate because you have to look at the "snapshot" field if it exists, and otherwise fall back to the "normal" field. Fix these issues by having getchainstates just return a flat list of chainstates ordered by work, and adding new chainstate "validated" field alongside the existing "snapshot_blockhash" so it is explicit if a chainstate was originally loaded from a snapshot, and whether the snapshot has been validated.
2023-10-05net: move MaybeFlipIPv6toCJDNS() from net to netbaseVasil Dimov
It need not be in the `net` module and we need to call it from `LookupSubNet()`, thus move it to `netbase`.
2023-10-05net: move IsReachable() code to netbase and encapsulate itVasil Dimov
`vfLimited`, `IsReachable()`, `SetReachable()` need not be in the `net` module. Move them to `netbase` because they will be needed in `LookupSubNet()` to possibly flip the result to CJDNS (if that network is reachable). In the process, encapsulate them in a class. `NET_UNROUTABLE` and `NET_INTERNAL` are no longer ignored when adding or removing reachable networks. This was unnecessary.
2023-10-05fuzz: ConsumeNetAddr(): avoid IPv6 addresses that look like CJDNSVasil Dimov
The fuzz testing framework runs as if `-cjdnsreachable` is set and in this case addresses like `{net=IPv6, addr=fc...}` are not possible.
2023-10-05net: put CJDNS prefix byte in a constantVasil Dimov
2023-10-05Merge bitcoin/bitcoin#28558: Make PeerManager own a FastRandomContextfanquake
4cafe9f176e93ebb6c38abb12140e8d8be005cbf [test] Make PeerManager's rng deterministic in tests (dergoegge) fecec3e1c661ba273470ecc5ef12d4c070b53050 [net processing] FeeFilterRounder doesn't own a FastRandomContext (dergoegge) 47520ed209d9341702a0fb6006bee6f63f7da42e [net processing] Make fee filter rounder non-global (dergoegge) 77506f4ac6b3a3d7396a3a6101345019e05b3b10 [net processing] Addr shuffle uses PeerManager's rng (dergoegge) a648dd79e5ebfdb627d0221b1207862efb664dfc [net processing] PushAddress uses PeerManager's rng (dergoegge) 87c706713e5d1c78bad943a42bf7c69047d28ea5 [net processing] PeerManager holds a FastRandomContext (dergoegge) Pull request description: This lets us avoid some non-determinism in tests (also see #28537). ACKs for top commit: MarcoFalke: re-ACK 4cafe9f176e93ebb6c38abb12140e8d8be005cbf 🕗 glozow: concept && light code review ACK 4cafe9f176e93ebb6c38abb12140e8d8be005cbf Tree-SHA512: 3c18700773d0bc547ccb6442c41567e6f26b0b50fab5b79620da417ec91b9c0ae1395d15258da3aa4a91447b8ce560145dd135e39fbbd0610749e528e665b111
2023-10-05test: display abrupt shutdown errors in console outputfurszy
Making it easier to debug errors in the CI environment, particularly in scenarios where it's not immediately clear what happened nor which node crashed (or shutdown abruptly).
2023-10-05i2p: destroy the session if we get an unexpected error from the I2P routerVasil Dimov
From https://geti2p.net/en/docs/api/samv3: If SILENT=false was passed, which is the default value, the SAM bridge sends the client a ASCII line containing the base64 public destination key of the requesting peer So, `Accept()` is supposed to receive a Base64 encoded destination of the connecting peer, but if it receives something like this instead: STREAM STATUS RESULT=I2P_ERROR MESSAGE="Session was closed" then destroy the session.
2023-10-05i2p: also sleep after errors in Accept()Vasil Dimov
Background: `Listen()` does: * if the session is not created yet * create the control socket and on it: * `HELLO` * `SESSION CREATE ID=sessid` * leave the control socked opened * create a new socket and on it: * `HELLO` * `STREAM ACCEPT ID=sessid` * read reply (`STREAM STATUS`) Then a wait starts, for a peer to connect. When connected, `Accept()` does: * on the socket from `STREAM ACCEPT` from `Listen()`: read the Base64 identification of the connecting peer Problem: The I2P router may be in such a state that this happens in a quick succession (many times per second, see https://github.com/bitcoin/bitcoin/issues/22759#issuecomment-1609907115): `Listen()`-succeeds, `Accept()`-fails. `Accept()` fails because the I2P router sends something that is not Base64 on the socket: STREAM STATUS RESULT=I2P_ERROR MESSAGE="Session was closed" We only sleep after failed `Listen()` because the assumption was that if `Accept()` fails then the next `Listen()` will also fail. Solution: Avoid filling the log with "Error accepting:" messages and sleep also after a failed `Accept()`. Extra changes: * Reset the error waiting time after one successful connection. Otherwise the timer will remain high due to problems that have vanished long time ago. * Increment the wait time less aggressively.
2023-10-05ci: Avoid cache depends/buildMarcoFalke
2023-10-05Merge bitcoin/bitcoin#28588: test: BIP324: add checks for v1 prefix matching ↵fanquake
/ wrong network magic detection e1308967e1a7e0ab275ab4c6f2f94c4ca0ee517b test: BIP324: add checks for v1 prefix matching / wrong network magic detection (Sebastian Falbesoner) Pull request description: This PR adds missing test coverage for the detection of incoming v1 connections and wrong network magic on BIP324-enabled (i.e. running with `-v2transport=1`) nodes. Both checks are using prefix sizes of 16 bytes (previously only 12 bytes were used for the v1 prefix matching, which was fixed by PR #28577). ACKs for top commit: Sjors: utACK e1308967e1a7e0ab275ab4c6f2f94c4ca0ee517b MarcoFalke: lgtm ACK e1308967e1a7e0ab275ab4c6f2f94c4ca0ee517b Tree-SHA512: d4d1567277297f42c543b9638a6c64d14b17ff0ddbf85a7efff22f45c619478139dbedcb9dc4f449b4814b00856ee43644f15df1aa20c8931d5496a607ca2fd4
2023-10-05test: Bump walletpassphrase timeouts to avoid intermittent issuesMarcoFalke
2023-10-05headerssync: update params for 26.xfanquake
2023-10-05kernel: update m_assumed_* chain params for 26.xfanquake
2023-10-05kernel: update chainTxData for 26.xfanquake
2023-10-05kernel: update nMinimumChainWork & defaultAssumeValid for 26.xfanquake
2023-10-05Merge bitcoin/bitcoin#25970: Add headerssync tuning parameters optimization ↵fanquake
script to repo 3d420d8f28f2d351abf8b0afe90848110e15d50c Add instructions for headerssync-params.py to release-process.md (Pieter Wuille) 53d7d35b5899685cd1577156250068e0cab502f4 Update parameters in headerssync.cpp (Pieter Wuille) 7899402cff708319b1c5181242a97557eefe1ae7 Add headerssync-params.py script to the repository (Pieter Wuille) Pull request description: Builds upon #25946, as it incorporates changes based on the selected values there. This adds the headerssync tuning parameters optimization script from https://gist.github.com/sipa/016ae445c132cdf65a2791534dfb7ae1 to the repository, updates the parameters based on its output, and adds release process instructions for doing this update in the future. A few considerations: * It would be a bit cleaner to have these parameters be part of `CChainParams`, but due to the nature of the approach, it really only applies to chains with unforgeable proof-of-work, which we really can only reasonably expect from mainnet, so I think it's fine to keep them local to `headerssync.cpp`. Keeping them as compile-time evaluatable constants also has a (likely negligible) performance impact (avoiding runtime modulo operations). * If we want to make sure the chainparams and headerssync params don't go out of date, it could be possible to run the script in CI, and and possibly even have the parameters be generated automatically at build time. I think that's overkill for how unfrequently these need to change, and running the script has non-trivial cost (~minutes in the normal python interpreter). * A viable alternative is just leaving this out-of-repo entirely, and just do ad-hoc updating from time to time. Having it in the repo and release notes does make sure it's not forgotten, though adds a cost to contributors/maintainers who follow the process. ACKs for top commit: ajtowns: reACK 3d420d8f28f2d351abf8b0afe90848110e15d50c Tree-SHA512: 03188301c20423c72c1cbd008ccce89b93e2898edcbeecc561b2928a0d64e9a829ab0744dc3b017c23de8b02f3c107ae31e694302d3931f4dc3540e184de1963
2023-10-05qt: enable -ltcg for windows HOSTfanquake
Patch around multiple definition issues in Qt. Co-authored-by: Cory Fields <cory-nospam-@coryfields.com>
2023-10-05Merge bitcoin-core/gui#754: Add BIP324-specific labels to peer detailsHennadii Stepanov
d9c4e344d70bbf31ccb7162d83d4bd25762bc678 qt: Add "Session id" label to peer details (Hennadii Stepanov) f08adec886febbfe038cedc32970c27c6f72bd5f qt: Add "Transport" label to peer details (Hennadii Stepanov) Pull request description: This PR adds BIP324-specific labels to the peer details widget: - a transport version - a session id See: https://github.com/bitcoin/bitcoin/pull/28331#issuecomment-1693239025. ![image](https://github.com/bitcoin-core/gui/assets/32963518/0e0b4c92-dde0-4b2e-b285-a2c69ef09efc) ACKs for top commit: achow101: ACK d9c4e344d70bbf31ccb7162d83d4bd25762bc678 RandyMcMillan: ACK d9c4e34 theStack: Tested re-ACK d9c4e344d70bbf31ccb7162d83d4bd25762bc678 MarnixCroes: tACK d9c4e344d70bbf31ccb7162d83d4bd25762bc678 Tree-SHA512: 524e634b1eedcae535d5c2a10dd8dea90d33d65d6790614f86ab6387a0ec9ee4bbc7646b8c20a5b3f1bccbb69bc52a46514e2b28cb4588979834d945b1f89b3a
2023-10-05test: BIP324: add checks for v1 prefix matching / wrong network magic detectionSebastian Falbesoner
2023-10-04Merge bitcoin/bitcoin#28577: net: raise V1_PREFIX_LEN from 12 to 16Andrew Chow
ba2e5bfc67dcffca26af9e231652ada1767cbeb2 net: raise V1_PREFIX_LEN from 12 to 16 (Pieter Wuille) Pull request description: A "version" message in the V1 protocol starts with a fixed 16 bytes: * The 4-byte network magic * The 12-byte command string: "version" plus 5 0x00 bytes The current code detects incoming V1 connections by just looking at the first 12 bytes (matching an [earlier version](https://github.com/bitcoin/bips/pull/1496) of BIP324), but 16 bytes is more precise. This isn't an observable difference right now, as a 12 byte prefix ought to be negligible already, but it may become observable with future extensions to the protocol, so make the code match the specification. ACKs for top commit: achow101: ACK ba2e5bfc67dcffca26af9e231652ada1767cbeb2 theStack: re-ACK ba2e5bfc67dcffca26af9e231652ada1767cbeb2 mzumsande: Code review ACK ba2e5bfc67dcffca26af9e231652ada1767cbeb2 Tree-SHA512: 64876b03613bd1c5dda82f4ca1b367014365f9ae4cfa30f45c5758a563c68cbea81a98d02ba616c264674c204517aac8b7de94da10f32e77b56267a43710c651
2023-10-04Merge bitcoin-core/gui#757: Add wallet name to address book page titleHennadii Stepanov
58c9b50a952951cb326c99ba86cb706a1e7d533e gui: Add wallet name to address book page (pablomartin4btc) Pull request description: It fixes bitcoin-core/gui#756. Each address book page window it's now labeled with the wallet name they were opened with, so the user can easily identify which addresses belong to which wallet even when there are many windows opened. It's a helpful enhancement for users managing multiple wallets. ![image](https://github.com/bitcoin-core/gui/assets/110166421/628e37bb-87b9-42fb-9158-bffdd8428bcb) ACKs for top commit: hebasto: ACK 58c9b50a952951cb326c99ba86cb706a1e7d533e, tested on Ubuntu 22.04. Tree-SHA512: 82febc020653560281da144cd35c672c49ca9f48b23d173eb19395e9ab4d045500295a9b5f24c82efdbf6e7ea70c87e733207cb6a31d3f84828b27e3b2df558b
2023-10-04gui: Add wallet name to address book pagepablomartin4btc
Extend addresstablemodel to return the display name from the wallet and set it to the addressbookpage window title when its model is set.
2023-10-04Merge bitcoin/bitcoin#27823: init: return error when block index is ↵Andrew Chow
non-contiguous, fix feature_init.py file perturbation d27b9a2248476439ddab7700327f074005a810d5 test: fix feature_init.py file perturbation (Martin Zumsande) ad66ca1e475d2546dbbda206465307613108a15d init: abort loading of blockindex in case of missing height. (Martin Zumsande) Pull request description: When the block index database is non-contiguous due to file corruption (i.e. it contains indexes of height `x-1` and `x+1`, but not `x`), bitcoind can currently crash with an assert in `BuildSkip()` / `GetAncestor()` during `BlockManager::LoadBlockIndex()`: ``` bitcoind: chain.cpp:112: const CBlockIndex* CBlockIndex::GetAncestor(int) const: Assertion `pindexWalk->pprev' failed. ``` This PR changes it such that we instead return an `InitError` to the user. I stumbled upon this because I noticed that the file perturbation in `feature_init.py` wasn't working as intended, which is fixed in the second commit: * Opening the file twice in one `with` statement would lead to `tf_read` being empty, so the test wouldn't perturb anything but replace the file with a new one. Fixed by first opening for read, then for write. * We need to restore the previous state after perturbations, so that only the current perturbation is active and not a mix of the current and previous ones. * I also added `checkblocks=200` to the startup parameters so that corruption in earlier blocks of `blk00000.dat` is detected during init verification and not ignored. After fixing `feature_init.py` like that I'd run into the `assert` mentioned above (so running the testfix from the second commit without the first one is a way to reproduce it). ACKs for top commit: achow101: ACK d27b9a2248476439ddab7700327f074005a810d5 furszy: Code ACK d27b9a224 fjahr: Code review ACK d27b9a2248476439ddab7700327f074005a810d5 Tree-SHA512: 2e54da6030c5813c86bd58f816401e090bb43c5b834764a5e3c0e55dbfe09e423f88042cab823db3742088204b274d4ad2abf58a3832a4b18328b11a30bf7094
2023-10-04Merge bitcoin/bitcoin#28561: build: Update `qt` package up to 5.15.10fanquake
6988a2f097e9af50e1b4222550b2593bfc5685ea build: Update qt package up to 5.15.10 (Hennadii Stepanov) Pull request description: The Qt 5.15.10 contains at least three important for us fixes: - https://github.com/qt/qtbase/commit/8bb90ab760310c9bc82b6ecbe068532fcb4e7822, which allows us to drop the [`dont_hardcode_x86_64.patch`](https://github.com/bitcoin/bitcoin/blob/fd8ab08558ccfb62f2d0a64d2d0d4dcefba977bc/depends/patches/qt/dont_hardcode_x86_64.patch) - https://github.com/qt/qtbase/commit/8467beddb7239cc213ae13900fa30e3d26df5e78, which allows us to drop the [`fix_montery_include.patch`](https://github.com/bitcoin/bitcoin/blob/fd8ab08558ccfb62f2d0a64d2d0d4dcefba977bc/depends/patches/qt/fix_montery_include.patch) - https://github.com/qt/qtbase/commit/df08a21fa4e7139d46ec68bcf264c922789c4f3a, which addresses https://github.com/bitcoin/bitcoin/pull/28349#issuecomment-1743519614 ACKs for top commit: fanquake: ACK 6988a2f097e9af50e1b4222550b2593bfc5685ea. Tree-SHA512: 838c44cf0d7508714f35887bb1f0983e59d96764f08f467bbd03d102d7152e797daeedc178afb03141115cc3be623e4ef7c4c4c65c0a8d1f0bb9702c9a6f8fc6
2023-10-04Merge bitcoin/bitcoin#28589: test: assumeutxo func test race fixesAndrew Chow
7e4003226030a04a19c718a4b1b83b4ca40ca33f tests: assumeutxo: accept final height from either chainstate (James O'Beirne) 5bd2010f024b5bcccf1d57bae6fc36c53f5facc5 test: assumeutxo: avoid race in functional test (James O'Beirne) 7005a01c19001ab5821731597656f8bc5e8c11e3 test: add wait_for_connect to BitcoinTestFramework.connect_nodes (James O'Beirne) Pull request description: Fixes https://github.com/bitcoin/bitcoin/issues/28585. Fixes a few races within the assumeutxo tests: - In general, `-stopatheight` can't be used with `connect_nodes` safely because the latter performs blocking assertions that are racy with the stopatheight triggering. - Now that the snapshot chainstate is listed as `normal` after background validation, accept the final height from either chainstate. ACKs for top commit: MarcoFalke: lgtm ACK 7e4003226030a04a19c718a4b1b83b4ca40ca33f fjahr: Code review ACK 7e4003226030a04a19c718a4b1b83b4ca40ca33f achow101: ACK 7e4003226030a04a19c718a4b1b83b4ca40ca33f ryanofsky: Code review ACK 7e4003226030a04a19c718a4b1b83b4ca40ca33f Tree-SHA512: 8cbd2a0ca8643f94baa0ae3561dcf68c3519d5ba851c6049e1768f28cae6434f47ffc28d404bf38ed11030ce3f00aae0a8be3f6d563e6ae6680d83c928a173d8
2023-10-04Merge bitcoin/bitcoin#28567: ci: Only run functional tests on native windows ↵fanquake
in master aba4a5887b44bf7cbee9ea0a8e02bb92c1b4147b ci: Only run functional tests on windows in master (Fabian Jahr) Pull request description: This idea was discussed [here](https://github.com/bitcoin/bitcoin/pull/28509#issuecomment-1740841988). ACKs for top commit: hebasto: ACK aba4a5887b44bf7cbee9ea0a8e02bb92c1b4147b Tree-SHA512: 89fd6352b585bae3538d5350b0404c216a8225fe356d408c1ebe3394e7b9a190d65639f4eef310056e020909928d7a1f2de25585c97d2ac087d1a9f72af281eb
2023-10-04ci: Only run functional tests on windows in masterFabian Jahr
2023-10-04tests: assumeutxo: accept final height from either chainstateJames O'Beirne
2023-10-04descriptors: disallow hybrid public keysPieter Wuille
The descriptor documentation (doc/descriptors.md) and BIP380 explicitly require that hex-encoded public keys start with 02 or 03 (compressed) or 04 (uncompressed). However, the current parsing/inference code permit 06 and 07 (hybrid) encoding as well. Fix this.
2023-10-04test: assumeutxo: avoid race in functional testJames O'Beirne