Skip to content

backport: bitcoin#28195, #28244, #28246, #28284, #28292, #28575, #28595, partial bitcoin-core/gui#119 - #8159

Open
knst wants to merge 40 commits into
dashpay:developfrom
knst:bp-v26-p12
Open

knst wants to merge 40 commits into
dashpay:developfrom
knst:bp-v26-p12

Conversation

@knst

@knst knst commented Nov 15, 2026 •

Copy link
Copy Markdown
Collaborator

STACKED ON #8158

Dear reviewers, review commits only from CHECKPOINT: bp-v26-p11, other commits should be reeviewed in its own PRs

What was done?

Regular backports from Bitcoin Core v26.

Extra adaptation to retry the macOS SDK download in Guix setup-sdk, same to bitcoin#28296

Extra fixes for bitcoin#28287 to unify with upsteram bitcoin Core

How Has This Been Tested?

N/A

Breaking Changes

N/A

Checklist:

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation
  • I have assigned this pull request to a milestone (if you have permission to set one)

knst and others added 30 commits November 15, 2026 20:52
p2p_instantsend.py asserted that the key "confirmation" was absent from
getrawtransaction, but the key is "confirmations", so the check that a
transaction without a lock is not mined before it is 10 minutes old never
ran. It would have failed: the isolated node's mocktime lagged behind the
bumps made while waiting for the lock, so the transaction was already old
enough. Sync the isolated node's clock and assert the early block leaves
the transaction in the mempool. The rejection of the doublespend block was
checked with waitforblock timeouts of 10 ms and 1 ms, before the block
could arrive; wait for it to be listed as invalid instead.

feature_masternode_params.py only logged the masternode's services and
indexes and asserted getblockcount() >= 0, and looked the block filter
index up under the wrong name, so its "regular node has no filter index"
check could not fail either. Assert the service bit and the index.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>

Co-authored-by: pasta <pasta@dashboost.org>
feature_addressindex.py and feature_spentindex.py toggled the index off
and on at genesis, before any block the index could miss. The toggle now
covers a spend mined while the index is disabled, and the index has to
catch up when it is turned back on.

feature_mnehf.py asserted that a payload it had just filled in still
contained those values, and polled activation one block at a time. The
payload check is gone. Activation is mined across the BIP9 windows and
the started, locked_in and active states are checked.

feature_masternode_payout_shares.py asserted that v24 was active after a
loop that only exits once it is.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-authored-by: Cursor <cursoragent@cursor.com>

Co-authored-by: pasta <pasta@dashboost.org>
…bled

A received total greater than zero still passed if only one of the two
coinbases was indexed. Compare it with the sum paid to the address by
both blocks.

Co-authored-by: Cursor <cursoragent@cursor.com>

Co-authored-by: pasta <pasta@dashboost.org>
Setup already mines past height 100, so the old loop was a no-op and the helper's pending-fork check would fail. The minimum activation height now stays above that premine.

Co-authored-by: Cursor <cursoragent@cursor.com>

Co-authored-by: pasta <pasta@dashboost.org>
…tion

6e8f646 removed StrFormatInternalBug quote delimitation (Reese Russell)

Pull request description:

  This PR rectifies an unnecessary set of quotes delimiting the contents of  ```StrFormatInternalBug```. This is a follow up to MarcoFalke bitcoin#28123 (comment).  The method of action was to remove the escaped quotes that were a part of strprintf. A single functional test case was modified to reflect the new output format.

  ```STR_INTERNAL_BUG``` was applied to bitcoin#28123 in ```std::string RPCArg::ToString(const bool oneline)``` in ```rpc/util.cpp```

  The results can be seen below.

  Previously
  ![image](https://github.com/bitcoin/bitcoin/assets/3104223/53f9ea59-317f-4c62-9fc1-04255eeb4641)

  This PR
  ![image](https://github.com/bitcoin/bitcoin/assets/3104223/5c6a3110-f1f3-4b3c-8e8a-9c8f1c3176e7)

  Additional context can be found here.
  bitcoin#28123 (comment)

  Thank you.

ACKs for top commit:
  MarcoFalke:
    review ACK 6e8f646
  stickies-v:
    ACK 6e8f646

Tree-SHA512: 35317e31a527630495b566407e37db9941dab7f81cfaeb1ea3309683c48e4273284645ad615f73e646a137b4f2ae35933603e9182a7dbdd22cac98d038c491dc

Co-authored-by: fanquake <fanquake@gmail.com>
CDeterministicMN gated nType on the stream version: it was written when the version was CLIENT_VERSION (taken to mean "disk") or at least DMN_TYPE_PROTO_VERSION (taken to mean "network"), and defaulted to MnType::Regular otherwise.
The network branch is dead: nothing sends CDeterministicMN over P2P, peers get CSimplifiedMNListEntry instead.

So nType is always written and read, and the on-disk bytes do not change.
Dropping the gate removes the last dependency of CDeterministicMN on the stream version, which the versionless DataStream used by dbwrapper after the following backports does not provide.
… and CDiskBlockIndex

e73d2a8 refactor: remove clientversion include from dbwrapper.h (Cory Fields)
4240a08 refactor: Use DataStream now that version/type are unused (Cory Fields)
f15f790 Remove version/hashing options from CBlockLocator/CDiskBlockIndex (Cory Fields)

Pull request description:

  This is also a much simpler replacement for bitcoin#28327.

  There are version fields in `CBlockLocator` and `CDiskBlockIndex` that have always been written but discarded when read.

  I intended to convert them to use SerParams as introduced by bitcoin#25284, which [ended up looking like this](theuni@3e3af45). However because we don't currently have any definition of what a hash value would mean for either one of those, and we've never assigned the version field any meaning, I think it's better to just not worry about them.

  If we ever need to assign meaning in the future, we can introduce `SerParams` as was done for `CAddress`.

  As for the dummy values chosen:

  `CDiskBlockIndex::DUMMY_VERSION` was easy as the highest ever client version, and I don't expect any objection there.

  `CBlockLocator::DUMMY_VERSION` is hard-coded to the higest _PROTOCOL_ version ever used. This is to avoid a sudden bump that would be visible on the network if CLIENT_VERSION were used instead. In the future, if we ever need to use the value, we can discard anything in the CLIENT_VERSION range (for a few years as needed), as it's quite a bit higher.

  While reviewing, I suggest looking at the throwaway `SerParams` commit above as it shows where the call-sites are. I believe that should be enough to convince one's self that hashing is never used.

ACKs for top commit:
  TheCharlatan:
    Re-ACK e73d2a8
  ajtowns:
    reACK e73d2a8

Tree-SHA512: 45b0dd7c2e918493e2ee92a8e35320ad17991cb8908cb811150a96c5fd584ce177c775baeeb8675a602c90b9ba9203b8cefc0a2a0c6a71078b1d9c2b41e1f3ba

Dash adaptations:
- CDiskBlockIndex::DUMMY_VERSION is 240100, Dash's current CLIENT_VERSION
  (10000 * 24 + 100 * 1 + 0 from _CLIENT_VERSION_MAJOR/MINOR/BUILD in
  configure.ac, per src/clientversion.h), instead of upstream's 259900.
- CBlockLocator::DUMMY_VERSION is 70242, Dash's highest PROTOCOL_VERSION
  (src/version.h), instead of upstream's 70016.
- Neither type is hashed with SER_GETHASH anywhere in Dash, so dropping
  that branch changes nothing.
- The CDBWrapper::ReadDataStream() overloads, which upstream does not
  have, now fill a DataStream as well, and so do their callers in
  evo/deterministicmns.cpp, llmq/dkgsessionmgr.cpp, llmq/quorums.cpp,
  llmq/quorumsman.cpp and llmq/signing.cpp. None of them needs a stream
  version or type: they decode BLS version wrappers, CRecoveredSig,
  recovered-sig markers, raw bytes and the legacy CDeterministicMNListDiff
  format.
- dbwrapper.h keeps including clientversion.h: Dash's CDBTransaction
  still estimates memory usage with ::GetSerializeSize(v, CLIENT_VERSION)
  and CDBWrapper::CompactRange() still builds SER_DISK/CLIENT_VERSION key
  streams. The upstream include additions to the files that use
  CLIENT_VERSION directly are kept.

Co-authored-by: fanquake <fanquake@gmail.com>
…File and CAutoFile

BACKPORT NOTE:
CDeterministicMN, CDiskBlockIndex and CBlockLocator no longer read GetVersion() (see bitcoin#28428 and "refactor: always serialize CDeterministicMN::nType")

dbwrapper.cpp no longer uses CLIENT_VERSION, so its clientversion.h include is dropped. dbwrapper.h keeps it for CDBTransaction's GetSerializeSize() estimate and CompactRange().

Backport done in full now

----

fa19c91 scripted-diff: Rename CBufferedFile to BufferedFile (MarcoFalke)
fa2f241 Remove unused GetType() from CBufferedFile and CAutoFile (MarcoFalke)
5c2b3cd dbwrapper: Use DataStream for batch operations (TheCharlatan)

Pull request description:

  This refactor is required for bitcoin#28052 and bitcoin#28451

  Thus, split it out.

ACKs for top commit:
  ajtowns:
    utACK fa19c91
  TheCharlatan:
    ACK fa19c91

Tree-SHA512: d9c232324702512e45fd73ec3e3170f1e8a8c8f9c49cb613a6b693a9f83358914155527ace2517a2cd626a0cedcada56ef70a2a7812edafb1888fd6765eebba2

Co-authored-by: fanquake <fanquake@gmail.com>
…ockstore

de8f912 test: cover read-only blockstore (Matthew Zipkin)
5c2185b ci: enable chattr +i capability inside containers (Matthew Zipkin)
e573f24 unit test: add coverage for BlockManager (Matthew Zipkin)

Pull request description:

  This PR adds unit and functional tests to cover the behavior described in dashpay#2039. In particular, that bitcoind will crash on startup if a reindex is requested but the `blk` files are read-only. Eventually this behavior can be updated with bitcoin#27039. This PR just commits the test coverage from bitcoin#27039 as suggested in bitcoin#27039 (comment)

ACKs for top commit:
  jonatack:
    ACK de8f912 modulo suggestions in bitcoin#27850 (comment), tested on macOS, but not on Linux for the Linux-related change in the last push
  achow101:
    ACK de8f912
  MarcoFalke:
    lgtm ACK de8f912 📶

Tree-SHA512: b9bd684035dcea11c901b649fc39f397a2155a9a8459f3348e67947e387e45312fddeccb52981aef486f8a31deebb5356a7901c1bb94b78f82c24192a369af73

Co-authored-by: Andrew Chow <github@achow101.com>
262ab8e Add package evaluation fuzzer (Greg Sanders)

Pull request description:

  This fuzzer target caught the issue in bitcoin#28251 within 5 minutes on master branch, and an additional issue which I've applied a preliminary patch to cover.

  Fuzzer target does the following:

  1) Picks mempool confgs, including max package size, count, mempool size, etc
  2) Generates 1 to 26 transactions with arbitrary coins/fees, the first N-1 spending only confirmed outpoints
  3) Nth transaction, if >1, sweeps all unconfirmed outpoints in mempool
  4) If N==1, it may submit it through single-tx submission path, to allow for more interesting topologies
  5) Otherwise submits through package submission interface
  6) Repeat 1-5  a few hundred times per mempool instance

  In other words, it ends up building chains of txns in the mempool using parents-and-children packages, which is currently the topology supported on master.

  The test itself is a direct rip of tx_pool.cpp, with a number of assertions removed because they were failing for unknown reasons, likely due to the notification changes of single tx submission to package, which is used to track addition/removal of transactions in the test. I'll continue working on re-adding these assertions for further invariant testing.

ACKs for top commit:
  murchandamus:
    ACK 262ab8e
  glozow:
    reACK 262ab8e
  dergoegge:
    tACK 262ab8e

Tree-SHA512: 190784777d0f2361b051b3271db8f79b7927e3cab88596d2c30e556da721510bd17f6cc96f6bb03403bbf0589ad3f799fa54e63c1b2bd92a2084485b5e3e96a5

Co-authored-by: glozow <gloriajzhao@gmail.com>
Dash has no replace-by-fee, so the set holds every outpoint a fuzzed
transaction may spend, not the ones spendable through a replacement.
…n package context

eb8f58f Add functional test to catch too large vsize packages (Greg Sanders)
1a579f9 Handle over-sized (in virtual bytes) packages with no in-mempool ancestors (Greg Sanders)
bc013fe Bugfix: Pass correct virtual size to CheckPackageLimits (Luke Dashjr)
533660c Replace MAX_PACKAGE_SIZE with MAX_PACKAGE_WEIGHT to avoid vbyte confusion (Greg Sanders)

Pull request description:

  (Alternative) Minimal subset of bitcoin#28345 to:

  1) Replace MAX_PACKAGE_SIZE with MAX_PACKAGE_WEIGHT which accounts for additional WU necessary to not exclude default chain limit transactions that would have been accepted individually. Avoids sigops vbyte confusion.
  2) pass correct vsize to chain limit evaluations in package context
  3) stop overly-large packages that have no existing mempool ancestors (also a bugfix by itself if someone sets non-standard chain limits)

  This should fix the known issues while not blocking additional refactoring later.

ACKs for top commit:
  achow101:
    ACK eb8f58f
  ariard:
    Re-Code ACK eb8f58f
  glozow:
    reACK eb8f58f

Tree-SHA512: 1b5cca1a526207e25d387fcc29a776a3198c3a013dc2b35c6275b9d5a64db2476c154ebf52e3a1aed0b9924c75613f21a946577aa760de28cadf0c9c7f68dc39

Co-authored-by: Andrew Chow <github@achow101.com>
…en*File()

fa56c42 Return CAutoFile from BlockManager::Open*File() (MarcoFalke)
9999b89 Make BufferedFile to be a CAutoFile wrapper (MarcoFalke)
fa389d9 refactor: Drop unused fclose() from BufferedFile (MarcoFalke)

Pull request description:

  This is required for bitcoin#28052, but makes sense on its own, because offloading logic to `CAutoFile` instead of re-implementing it allows to delete code and complexity.

ACKs for top commit:
  TheCharlatan:
    Re-ACK fa56c42
  willcl-ark:
    tACK fa56c42

Tree-SHA512: fe4638f3a6bd3f9d968cfb9ae3259c9d6cd278fe2912cbc90289851311c8c781099db4c160e775960975c4739098d9af801a8d2d12603f371f8edfe134d8f85a

Co-authored-by: fanquake <fanquake@gmail.com>
…ap-add LINUX_IMMUTABLE

fa40b3e test: Avoid test failure on Linux root without cap-add LINUX_IMMUTABLE (MarcoFalke)

Pull request description:

  This turns a test failure on Linux when running the test as `root`, but without the `LINUX_IMMUTABLE` capability, into an early return, with a suggestion to turn on `LINUX_IMMUTABLE` next time (if possible).

ACKs for top commit:
  pinheadmz:
    utACK fa40b3e
  jonatack:
    ACK fa40b3e

Tree-SHA512: d986ff8aeae5f8267c21a23d5be16f7c5a4d4d3be045a6999d8b39c7b8672cfe915dedde762cc9965cdc4970940bffc4b0d1412833d8036d4425450eb6181f67

Co-authored-by: fanquake <fanquake@gmail.com>
… regtest

5b878be [doc] add release note for submitpackage (glozow)
7a9bb2a [rpc] allow submitpackage to be called outside of regtest (glozow)
5b9087a [rpc] require package to be a tree in submitpackage (glozow)
e32ba15 [txpackages] IsChildWithParentsTree() (glozow)
b4f28cc [doc] parent pay for child in aggregate CheckFeeRate (glozow)

Pull request description:

  Permit (restricted topology) submitpackage RPC outside of regtest. Suggested in bitcoin#26933 (comment)

  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 5b878be
  achow101:
    ACK 5b878be
  dergoegge:
    Code review ACK 5b878be
  ajtowns:
    ACK 5b878be
  ariard:
    Code Review ACK  5b878be. Though didn’t manually test the PR.

Tree-SHA512: 610365c0b2ffcccd55dedd1151879c82de1027e3319712bcb11d54f2467afaae4d05dca5f4b25f03354c80845fef538d3938b958174dda8b14c10670537a6524

Co-authored-by: Andrew Chow <github@achow101.com>
bfa0bd6  test: Use pathlib over os.path bitcoin#28362 (ns-xvrn)

Pull request description:

  In reference to issue  bitcoin#28362  refactoring of functional tests to use pathlib over os.path to reduce verbosity and increase the intuitiveness of managing file access.

ACKs for top commit:
  maflcko:
    re-ACK  bfa0bd6  🐨
  willcl-ark:
    ACK bfa0bd6

Tree-SHA512: fb0833c4039d09758796514e47567a93ac831cb0776ff1a7ed8299792ad132e83282ef80bea098a88ae1551d906f2a56093d3e8de240412f9080735d00d496d9

Co-authored-by: fanquake <fanquake@gmail.com>
5a0688a test: enable reindex readonly test on *BSD and macOS as root (Matthew Zipkin)

Pull request description:

  see bitcoin#27850 (comment)

  OpenBSD and FreeBSD don't have `chattr` but they do have `chflags`, use that method to make the block file immutable for the reindex_readonly test.

  Written and tested on a VPS running FreeBSD:
  ```
  FreeBSD freebsd-13-1 13.2-RELEASE-p4 FreeBSD 13.2-RELEASE-p4 GENERIC amd64
  ```

ACKs for top commit:
  maflcko:
    re-cr-lgtm-ACK 5a0688a
  jonatack:
    ACK 5a0688a tested on macOS only
  theStack:
    ACK 5a0688a

Tree-SHA512: 8c88d282d09c00355d22c4c504b779f60e420327a5e07bcf80fa77b97fefcb04952af9ceaf439d9033a0a2448cb26a02663fe6bddcd4a74792857cfbaf1c5162

Co-authored-by: fanquake <fanquake@gmail.com>
…from kernel headers

d506765 [refactor] Remove compat.h from kernel headers (TheCharlatan)
36193af [refactor] Remove netaddress.h from kernel headers (TheCharlatan)
2b08c55 [refactor] Add CChainParams member to CConnman (TheCharlatan)
f0d1d8b [refactor] Add missing includes for next commit (TheCharlatan)
534b314 kernel: Move MessageStartChars to its own file (TheCharlatan)
9be330b [refactor] Define MessageStartChars as std::array (TheCharlatan)
37e2b01 [refactor] Allow std::array<std::byte, N> in serialize.h (MarcoFalke)

Pull request description:

  This removes the non-consensus critical `protocol.h` and `netaddress.h` headers from the kernel headers. With this patch, they are no longer required to include in order to use the libbitcoinkernel library. This also allows for the removal of the `compat.h` header from the kernel headers.

  As an added future benefit it also reduces the number of of kernel headers that include the platform specific `bitcoin-config.h`.

  For those interested, the currently required kernel headers can be inspected visually with the [sourcetrail](https://github.com/CoatiSoftware/Sourcetrail) tool by looking at the required includes of `bitcoin-chainstate.cpp`.

  ---

  This is part of the [libbitcoinkernel project](bitcoin#27587), namely its stage 1 step 3: Decouple most non-consensus headers from libbitcoinkernel.

ACKs for top commit:
  stickies-v:
    re-ACK d506765
  hebasto:
    ACK d506765.
  ajtowns:
    utACK d506765
  MarcoFalke:
    lgtm ACK d506765 🍛

Tree-SHA512: 6f90ea510a302c2927e84d16900e89997c39b8ff3ce9d4effeb8a134bd29cc52bd9e81e51aaa11f7496bad00025b78a58b88c5a9e0bb3f4ebbe9a76309215fb7

Co-authored-by: fanquake <fanquake@gmail.com>
…validation code.

6eb33bd kernel: Add fatalError method to notifications (TheCharlatan)
7320db9 kernel: Add flushError method to notifications (TheCharlatan)
3fa9094 scripted-diff: Rename FatalError to FatalErrorf (TheCharlatan)
edb55e2 kernel: Pass interrupt reference to chainman (TheCharlatan)
e2d680a util: Add SignalInterrupt class and use in shutdown.cpp (TheCharlatan)

Pull request description:

  Get rid of all `ShutdownRequested` calls in validation code by introducing an interrupt object that applications can use to cancel long-running kernel operations.

  Replace all `AbortNode` calls in validation code with new fatal error and flush error notifications so kernel applications can be notified about failures and choose how to handle them.

  ---

  This pull request is part of the `libbitcoinkernel` project bitcoin#27587 https://github.com/orgs/bitcoin/projects/3 and more specifically its "Step 2: Decouple most non-consensus code from libbitcoinkernel".

  The pull request mostly allows dropping the kernel dependency on shutdown.cpp. The only dependency left after this is a `StartShutdown` call which will be removed in followup PR bitcoin#27711. This PR also drops the last reference to the `uiInterface` global in kernel code. The process of moving the `uiInterface` out of the kernel was started in bitcoin#27636.

  This pull request contains a subset of patches originally proposed in bitcoin#27711. It will be part of a series of changes required to make handling of interrupts (or in other words the current shutdown procedure) in the kernel library more transparent and less reliable on global mutable state. The set of patches contained here was originally proposed by @ryanofsky [here](bitcoin#27711 (comment)).

ACKs for top commit:
  achow101:
    light ACK 6eb33bd
  hebasto:
    ACK 6eb33bd, I have reviewed the code and it looks OK.
  ryanofsky:
    Code review ACK 6eb33bd. No changes since last review other than rebase.

Tree-SHA512: 7d2d05fa4805428a09466d43c11ae32946cbb25aa5e741b1eec9cd142e4de4bb311e13ebf1bb125ae490c9d08274f2d56c93314e10f3d69e7fec7445e504987c

Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
004903e test: Add Wallet Unlock Context Manager (Brandon Odiwuor)

Pull request description:

  Fixes bitcoin#28601, see bitcoin#28403 (comment)

  Add Context Manager to manage the locking and unlocking of locked wallets with a passphrase during testing.

ACKs for top commit:
  kevkevinpal:
    lgtm ACK [004903e](bitcoin@004903e)
  maflcko:
    lgtm ACK 004903e

Tree-SHA512: ab234c167e71531df0d974ff9a31d444f7ce2a1d05aba5ea868cc9452f139845eeb24ca058d88f058bc02482b762adf2d99e63a6640b872cc71a57a0068abfe8

Co-authored-by: fanquake <fanquake@gmail.com>
fa6b11a test: Throw error when -signetchallenge is non-hex (MarcoFalke)

Pull request description:

  Instead of silently parsing non-hex to an empty challenge, throw an error.

  Also, add missing includes while touching the file.

ACKs for top commit:
  kevkevinpal:
    ACK [fa6b11a](bitcoin@fa6b11a)
  kallewoof:
    ACK fa6b11a
  TheCharlatan:
    Nice, ACK fa6b11a

Tree-SHA512: 018ebbbf819ba7cdf0c6dd294fdfaa5ddb81b87058a8b9c57b96066d5b07e1656fd78f18e3cef375aebefa191fa515c2c70bc764880fa05f98f526334431a616

Co-authored-by: fanquake <fanquake@gmail.com>
ca91c24 index: verify blocks data existence only once (furszy)
fcbdaee init: don't start indexes sync thread prematurely (furszy)
2ec89f1 refactor: simplify pruning violation check (furszy)
c82ef91 make GetFirstStoredBlock assert that 'start_block' always has data (furszy)
430e702 refactor: index, decouple 'Init' from 'Start' (furszy)
225e213 refactor: init indexes, decouple 'Start()' from the creation step (furszy)
2ebc7e6 doc: describe 'init load' thread actions (Martin Zumsande)
0457510 scripted-diff: rename 'loadblk' thread name to 'initload' (furszy)
ed4462c init: start indexes sync earlier (furszy)

Pull request description:

  Simplifies index startup code, eliminating the `g_indexes_ready_to_sync` variable,
  deduplicating code and moving the prune violation check out of the `BaseIndex` class.

  Also makes startup more efficient by running the prune violation check once for all indexes
  instead of once for each index, and by delaying the prune violation check and moving it off
  of the main thread so the node can start up faster and perform the block data availability
  verification even when the '-reindex" or the "-reindex-chainstate" flags are enabled (which
  hasn't  being possible so far).

ACKs for top commit:
  ryanofsky:
    Code review ACK ca91c24. Just rebase and suggested changes since last review (Start return check, and code simplification)
  TheCharlatan:
    re-ACK ca91c24

Tree-SHA512: e9c98ce89aeb29e8d0f505f17b34aa54fe44efefbf017f4746e3b446ab4de25ade4f707254a0bbe4b99b69731b04a4067ce529eb7aa834ced196784b694cf7ce

Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
…f blockstorage

462390c refactor: Move stopafterblockimport handling out of blockstorage (TheCharlatan)

Pull request description:

  This has the benefit of moving this StartShutdown call out of the blockstorage file and thus out of the kernel's responsibility. The user can now decide if he wants to start shutdown / interrupt after a block import or not.

  This also simplifies bitcoin#28048, making it one fewer shutdown call to handle.

ACKs for top commit:
  MarcoFalke:
    lgtm ACK 462390c  🗝
  ryanofsky:
    Code review ACK 462390c. Just has been rebased and is a simpler change after bitcoin#27607

Tree-SHA512: 84e58256b1c61f10e7ec5ecf32916f40a2ab1ea7cce703de0fa1c61ee2be94bd45ed32718bc99903b6eff3e6d3d5b506470bf567ddbb444a58232913918e8ab8

Co-authored-by: Ryan Ofsky <ryan@ofsky.org>
…on code

31eca93 kernel: Remove StartShutdown calls from validation code (Ryan Ofsky)

Pull request description:

  This change drops the last kernel dependency on shutdown.cpp. It also adds new hooks for libbitcoinkernel applications to be able to interrupt kernel operations when the chain tip changes.

  This change is mostly a refactoring, but does slightly change `-stopatheight` behavior (see release note and commit message)

ACKs for top commit:
  TheCharlatan:
    ACK 31eca93
  furszy:
    Concept and light review ACK 31eca93
  hebasto:
    ACK 31eca93, I have reviewed the code and it looks OK.
  MarcoFalke:
    lgtm ACK 31eca93 🕷

Tree-SHA512: e26928436bcde658e842b1f92e9c24b1ce91031fb63b41aafccf3130bfff532b75338a269a2bb7558bff2973913f17b97a00fec3e7e0588e2ce44de097142047

Co-authored-by: Andrew Chow <github@achow101.com>
fae1d9c refactor: Remove unused GetTimeMillis (MarcoFalke)

Pull request description:

  The function is unused, not type-safe, and does not denote the underlying clock type. So remove it.

ACKs for top commit:
  willcl-ark:
    tACK fae1d9c

Tree-SHA512: 41ea7125d1964192b85a94265be974d02bf1e79b1feb61bff11486dc0ac811745156940ec5cad2ad1f94b653936f8ae563c959c1c4142203a55645fcb83203e8

Co-authored-by: fanquake <fanquake@gmail.com>
75a3291 doc: mention BIP324 support in bips.md (Pieter Wuille)
64ca721 test: enable v2 transport between nodes in some functional tests (Pieter Wuille)
05d19fb test: Functional test for opportunistic encryption (dhruv)
b815cce net: expose transport types/session IDs of connections in RPC and logs (Pieter Wuille)
432a62c net: reconnect with V1Transport under certain conditions (Pieter Wuille)
4d265d0 sync: modernize CSemaphore / CSemaphoreGrant (Pieter Wuille)
c73cd42 rpc: addnode arg to use BIP324 v2 p2p (dhruv)
62d21ee net: use V2Transport when NODE_P2P_V2 service flag is present (Pieter Wuille)
a4706bc rpc: don't report v2 handshake bytes in the per-type sent byte statistics (Sebastian Falbesoner)
abf343b net: advertise NODE_P2P_V2 if CLI arg -v2transport is on (Pieter Wuille)

Pull request description:

  Part of bitcoin#27634.

  This makes BIP324 support feature complete, through a (default off) `-v2transport` option for enabling V2 connections. If it is enabled:
  * The `NODE_P2P_V2` service flag (*1 << 11*) is advertized.
  * Inbound connections can use V1 or V2 (automatically detected based on the protocol used by the peer)
  * V2 connections are used on outbound when the `NODE_P2P_V2` service is available (or the new `use_v2` parameter is set on the `addnode` RPC).
  * V2 outbound connections that instantly fail get retried as V1.

  There are two new RPC fields, `"transport_protocol_type"` and `"session_id"`, in `getpeerinfo`.

ACKs for top commit:
  mzumsande:
    re-ACK 75a3291
  theStack:
    re-ACK 75a3291

Tree-SHA512: 90ea1cd37f3dce410a59ff5de1c2405891e8aa62318d0e06dcb68b21603fb0c061631526633f3d4fb630e63d2b8db407eed48e246befcbef3503bea893a4ff15

Co-authored-by: fanquake <fanquake@gmail.com>
…ters from BlockManager methods

fa69e3a Remove unused MessageStartChars parameters from BlockManager methods (MarcoFalke)

Pull request description:

  Seems odd to expose these for mocking, when it is not needed.

  Fix this by removing the the unused parameters and use the already existing member field instead.

ACKs for top commit:
  Empact:
    utACK fa69e3a
  dergoegge:
    utACK fa69e3a

Tree-SHA512: 7814e9560abba8d9c0926bcffc70f92e502d22f543af43671248f6fcd1433f35238553c0f05123fde6d8e0f80261af0ab0500927548115153bd68d57fe2da746

Co-authored-by: fanquake <fanquake@gmail.com>
fad0b67 ci: Use qemu-user through container engine (MarcoFalke)

Pull request description:

  Currently the CI containers always run on the host architecture, and only wrap `bitcoind` into `qemu-user` when needed. This has many issues:

  * The `i386` tasks can not be run on non-x86 hosts.
  * `config.guess` isn't present when building the CI image, which is fine. But it prints a warning, see bitcoin#27739 (review)
  * The python tests are run on the host architecture, making it harder to find architecture specific bugs. See for example bitcoin#27529 (comment)
  * All modern container engines support automatic dispatch to qemu-user, so it seems redundant to re-invent the wheel.

  Fix all issues by:
  * removing `HOST` from `ci/test/00_setup_env.sh`.
  * removing `QEMU_USER_CMD` and `ci/test/wrap-qemu.sh`.
  * removing `DPKG_ADD_ARCH` where possible, and pruning `PACKAGES` where possible.
  * specifying the architecture in `CI_IMAGE_NAME_TAG` to be used by the container engine.

ACKs for top commit:
  fanquake:
    ACK fad0b67 - this seems ok to me, and removes complexity from our CI system.

Tree-SHA512: 85e79f9f570e292d70a629d112fd4a6e6217d96226a1b665ed13485f616d84720ad2126b7d4b22fc603049f72fa7f2163b56a6bc276319fcd8b0496304ea4157

Co-authored-by: fanquake <fanquake@gmail.com>
knst and others added 10 commits November 15, 2026 20:52
91d924e Rename script/standard.{cpp/h} to script/solver.{cpp/h} (Andrew Chow)
bacdb2e Clean up script/standard.{h/cpp} includes (Andrew Chow)
f3c9078 Clean up things that include script/standard.h (Andrew Chow)
8bbe257 MOVEONLY: Move datacarrier defaults to policy.h (Andrew Chow)
7a172c7 Move CTxDestination to its own file (Andrew Chow)
145f36e Move Taproot{SpendData/Builder} to signingprovider.{h/cpp} (Andrew Chow)
86ea8be Move CScriptID to script.{h/cpp} (Andrew Chow)
b81ebff Remove ScriptHash from CScriptID constructor (Andrew Chow)
cba69dd Move MANDATORY_SCRIPT_VERIFY_FLAGS from script/standard.h to policy/policy.h (Anthony Towns)

Pull request description:

  Some future work needs to touch things in script/standard.{h/cpp}, however it is unclear if it is safe to do so as they are included in several different places that could effect standardness and consensus. It contains a mix of policy parameters, consensus parameters, and utilities only used by the wallet. This PR breaks up the various components and renames the files to clearly separate everything.

  * `CTxDestination` is moved to a new file `src/addresstype.{cpp/h}`
  * `TaprootSpendData` and `TaprootBuilder` (and their utility functions and structs) are moved to `SigningProvider` as these are used only during signing.
  * `CScriptID` is moved to `script/script.h` to be next to `CScript`.
  * `MANDATORY_SCRIPT_VERIFY_FLAGS` is moved to `interpreter.h`
  * The parameters `DEFAULT_ACCEPT_DATACARRIER` and `MAX_OP_RETURN_RELAY` are moved to `policy.h`
  * `standard.{cpp/h}` is renamed to `solver.{cpp/h}` since that's all that's left in the file after the above moves

ACKs for top commit:
  Sjors:
    ACK 91d924e
  ajtowns:
    ACK 91d924e
  MarcoFalke:
    ACK 91d924e 😇
  murchandamus:
    ACK 91d924e
  darosior:
    Code review ACK 91d924e.
  theStack:
    Code-review ACK 91d924e

Tree-SHA512: d347439890c652081f6a303d99b2bde6c371c96e7f4127c5db469764a17d39981f19884679ba883e28b733fde6142351dd8288c7bc61c379b7eefe7fa7acca1a

Co-authored-by: fanquake <fanquake@gmail.com>
…s types

fadf671 Refactor: Remove confusing static_cast (MarcoFalke)
faeea1a refactor: Add missing includes (MarcoFalke)

Pull request description:

  It seems confusing to use `static_cast<uint160>(bla)` to call the constructor of `uint160`. The normal and common way to call a constructor is by simply calling it. (`uint160{bla}`).

  Do this, and also drop the constructor completely where the existing `const&` reference is enough.

  Also, add missing includes while touching the file.

ACKs for top commit:
  vincenzopalazzo:
    ACK bitcoin@fadf671
  TheCharlatan:
    ACK fadf671

Tree-SHA512: 8fb9a72203a6461b1f4b38bb90943ca25a92b218fc87da2022b90802e7747350e3668a13db3189201ad30e2e39a51d6658fed4aad176fd52cecc1c7f972c3134

Co-authored-by: fanquake <fanquake@gmail.com>
fae4055 scripted-diff: Rename CBlockTreeDB -> BlockTreeDB (MarcoFalke)
faf6303 Fixup style of moved code (MarcoFalke)
fa65111 move-only: Move CBlockTreeDB to node/blockstorage (MarcoFalke)
fa86855 index: Drop legacy -txindex check (MarcoFalke)
fa69148 scripted-diff: Use blocks_path where possible (MarcoFalke)

Pull request description:

  The only reason for the check was to print a warning about an increase in storage use. Now that 22.x is EOL and everyone should have migrated (or decided to not care about storage use), remove the check.

  Also, a move-only commit is included. (Rebased from bitcoin#22242)

ACKs for top commit:
  TheCharlatan:
    ACK fae4055, though I lack historical context to really judge the second commit fa86855.
  stickies-v:
    ACK fae4055

Tree-SHA512: 9da8f48767ae52d8e8e21c09a40c949cc0838794f1856cc5f58a91acd3f00a3bca818c8082242b3fdc9ca5badb09059570bb3870850d3807b75a8e23b5222da1

Co-authored-by: fanquake <fanquake@gmail.com>
… of just scriptPubKey

ad0c469 wallet: Use CTxDestination in CRecipient rather than scriptPubKey (Andrew Chow)
07d3bdf Add PubKeyDestination for P2PK scripts (Andrew Chow)
1a98a51 Allow CNoDestination to represent a raw script (Andrew Chow)
8dd0670 Make WitnessUnknown members private (Andrew Chow)

Pull request description:

  For silent payments, we want to provide a `SilentPaymentsDestination` to be used as the recipient, which requires `CRecipient` to use something other than just the `scriptPubKey` as we cannot know the output script for a silent payment prior to transaction creation. `CTxDestination` seems like the obvious place to add a `SilentPaymentsDestination` as it is our internal representation of an address.

  In order to still allow paying to arbitrary scriptPubKeys (e.g. for data carrier outputs, or the user hand crafted a raw transaction that they have given to `fundrawtransaction`), `CNoDestination` is changed to contain raw scripts.

  Additionally, P2PK scripts are now interpreted as a new `PubKeyDestination` rather than `PKHash`. This results in some things that would have given an address for P2PK scripts to no longer do so. This is arguably more correct.

  `ExtractDestination`'s behavior is slightly changed for the above. It now returns `true` for those destinations that have addresses, so P2PK scripts now result in `false`. Even though it returns false for `CNoDestination`, the script will now be included in that `CNoDestination`.

  Builds on bitcoin#28244

ACKs for top commit:
  josibake:
    ACK bitcoin@ad0c469

Tree-SHA512: ef3f8f3c7284779d9806c77c85b21caf910a79a1f7e7f1b51abcc0d7e074f14e00abf30f625a13075e41d94dad6202c10ddff462c0ee74c2ca4aab585b145a52

Co-authored-by: fanquake <fanquake@gmail.com>
Every Guix CI run fetches the macOS SDK through setup-sdk, so a single
transient network error fails the whole build. Retry the download up to
three times.

This is the Dash-specific follow-up of bitcoin#28296, which adds
${CI_RETRY_EXE} before the same SDK curl in ci/test/01_base_install.sh.
Dash has no such file: its SDK download lives in setup-sdk, inside the
Guix container, which does not ship the retry helper, so curl's own
--retry is used instead.
The bitcoin#28287 backport (ac94de2) diverged from upstream for no
remaining reason:
- peer_id was read as int, while NodeId is int64_t, so valid peer ids
  above INT_MAX were rejected;
- msg was validated with IsHex() plus an empty-string special case and
  then parsed again with ParseHex(), although TryParseHex() (bitcoin#25227)
  was already available;
- the result was null instead of upstream's empty object.

Use upstream's body unchanged. sendmsgtopeer is a hidden test-only RPC
and no test checks its return value.
…nd+receive entries

BACKPORT NOTE: the dual send+receive records, the "any from me" criterion
(b9765ba), ignoring the change flag when we are not the sender
(2d182f7) and the send-before-receive sort (099dbe4) are taken. The
removal of the SendToSelf type (71fbdb7) is not, and Dash's own record
types are carried into upstream's per-output loop:
- SendToSelf stays as an aggregated record for a transaction whose inputs
  and outputs are all ours, because that is where CoinJoin is classified:
  CoinJoinSend, CoinJoinCollateralPayment, CoinJoinMakeCollaterals and
  CoinJoinCreateDenominations, plain SendToSelf otherwise. The enum value and
  the "To yourself" filter stay too: the type filter is saved as an enum
  bitmask in the "transactionTypeFilter" setting, so removing a value would
  shift every later type and reopen a saved filter as a different one.
- CoinJoinMixing (is_denominate) stays a single record and is checked first.
- Platform transfers, like coinbase, count as not from us, so they only get
  credit records (an asset unlock has no inputs).
- The 1-in-1-out collateral payment to OP_RETURN, DataTransaction outputs,
  the DS=1 CoinJoinSend marking and dust-receive detection keep their
  existing rules inside the new loop.
- CoinJoinSend sorts with the sends, since it can now be paired with a
  receive at the same output index.

099dbe4 GUI: TransactionRecord: When time/index/etc match, sort send before receive (Luke Dashjr)
2d182f7 Bugfix: Ignore ischange flag when we're not the sender (Luke Dashjr)
71fbdb7 GUI: Remove SendToSelf TransactionRecord type (Luke Dashjr)
f3fbe99 GUI: TransactionRecord: Refactor to turn send-to-self into send+receive pairs (Luke Dashjr)
b9765ba GUI: TransactionRecord: Use "any from me" as the criteria for deciding whether a transaction is a send or receive (Luke Dashjr)

Pull request description:

  Makes the GUI transaction list more like the RPC, and IMO clearer in general.

  As a side effect, this also fixes the GUI entries when a transaction is a net profit to us, but some inputs were also from us.

  Originally bitcoin#15115

  Has Concept ACKs from @*Empact @*jonasschnelli

ACKs for top commit:
  hebasto:
    ACK 099dbe4.

Tree-SHA512: 7d581add2f59431aa019126d54232a1f15723def5147d7a1b672e9b6d525b6e5a944cc437701aa1bd5bd0fbe557a3d1f4b239337f42bdba4fe1d3960442d0e3b

Co-authored-by: Hennadii Stepanov <32963518+hebasto@users.noreply.github.com>
BACKPORT NOTE: ci/test/06_script_b.sh does not exist in Dash, and Dash's CI
prints no system-info block. The kernel line goes into the two scripts that
run the tests inside the builder container, ci/dash/test_unittests.sh and
ci/dash/test_integrationtests.sh, after their skip checks: the failures it
helps to debug (e.g. TSan's "unexpected memory mapping" on newer kernels)
show up when tests run, not at build time. Both scripts only run in Linux
containers, so upstream's macOS branch has no counterpart.

fac054d ci: Print Linux kernel info (MarcoFalke)

Pull request description:

  Required to debug issues like bitcoin#28487 (comment). For example:

  ```
  FATAL: ThreadSanitizer: unexpected memory mapping 0x57cf8f031000-0x57cf8f173000

ACKs for top commit:
  hebasto:
    ACK fac054d

Tree-SHA512: 7eb158e52daffe5cbcdfa3ed1efb45e1930b80a2672558fe400c8d72ce59a8cbeb02296dfc2032721d511410885a1f057672fe8086ba1c72a494aef541bf7eb4

Co-authored-by: fanquake <fanquake@gmail.com>
…ub Actions

BACKPORT NOTE: upstream's .github/workflows/ci.yml does not exist in Dash.
Dash's ccache, ctcache and cppcheck caches already save only on pushes to the
default branch, and the depends caches are keyed by content. The one cache
still saved from pull request runs is the Guix job's /gnu/store plus depends
cache, keyed by github.sha, so every labelled PR run stored a new copy for
each target. It is split the same way: restore always (except tags), save
after a successful build only when the run is not pull_request_target, the
event Dash uses for pull requests instead of upstream's pull_request. This
also keeps PR head code from writing into a cache that develop pushes restore.

241d6ca ci: Disable cache save for pull requests in GitHub Actions (Hennadii Stepanov)

Pull request description:

  This PR disable cache save for pull requests in GitHub Actions.

  Otherwise, multiple pull requests fill GitHub Actions cache quota shortly.

  See a discussion [here](bitcoin#28187 (comment)).

  ---

  **NOTE** for the maintainers with "owner" permissions.

  This PR needs the `actions/cache/restore@*` and `actions/cache/save@*` acrions to be explicitly allowed in the repository's Actions permissions.

ACKs for top commit:
  MarcoFalke:
    lgtm ACK 241d6ca

Tree-SHA512: a7786c7ec99bfa6991bf6ae08fd7ed3546e8c5d083a1b2bae7638f6f31e77fdf2cf4fc69d85834faf87f98db1f4a82026ce1dc5fc1bc6650e8bf1c09bf7e90f5

Co-authored-by: fanquake <fanquake@gmail.com>
BACKPORT NOTE: upstream's docker volume mounts in ci/test/04_install.sh have
no Dash counterpart. Dash's depends caches already keep only depends/built
and depends/sources, and the macOS SDK lives in the CI image. The Guix job
was the exception: it also cached dash/depends/work, whose work/build stamp
files and intermediate trees are what upstream stops carrying between runs.
Drop that path from the Guix cache. Finished packages still come from
depends/built, so only packages that are rebuilt anyway start clean.

fac88a8 ci: Avoid cache depends/build (MarcoFalke)

Pull request description:

  Fixes bitcoin#28365 (maybe?)

ACKs for top commit:
  hebasto:
    ACK fac88a8

Tree-SHA512: c121f335f4b7d1f5f8f0508a17cee4d33dcf43c3928f9003a01dcc9ed0c45d1d912f7ff976e605b06c2f293ed21371d2dcace5562fe466bc444144790353bdd3

Co-authored-by: fanquake <fanquake@gmail.com>
@knst knst added this to the 24.1 milestone Nov 15, 2026
@thepastaclaw

thepastaclaw commented Nov 15, 2026 •

Copy link
Copy Markdown
Collaborator

⛔ Final review complete — 3 blocking finding(s) (commit 690dcd1) · triage: critical

@github-actions

github-actions Bot commented Nov 15, 2026 •

Copy link
Copy Markdown

Potential PR merge conflicts

This is advisory only. It does not block CI. This PR and each open PR below change the same files and cannot be merged together cleanly, so whichever of the two merges second will likely need a rebase:

@github-actions

Copy link
Copy Markdown

This pull request has conflicts, please rebase.

@thepastaclaw thepastaclaw left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Final validation — Phase 1 + Phase 2

This head is not buildable. CI reports the stale CRecipient member access, unresolved address-symbol references from the kernel library, and a GCC -Werror maybe-uninitialized failure caused by the new CNoDestination representation. The destination refactor also contains a Dash-specific recipient construction issue, an incorrect numeric sort format, and an omitted upstream fuzz-test transformation.

🔴 3 blocking | 🟡 2 suggestion(s) | 💬 1 nitpick(s)

4 finding(s) not shown inline (the lines are not part of this PR's diff)

🔴 Blocking: Update the BIP69 comparator for the renamed recipient field
src/wallet/spend.cpp:1111

CRecipient now stores its destination in dest, but this comparator still accesses the removed scriptPubKey member. The source-build CI logs show compilation failures at this exact line on the aarch64, Windows, and Linux builds. Compare the reconstructed scripts from the destinations instead.

return a.nAmount < b.nAmount || (a.nAmount == b.nAmount && GetScriptForDestination(a.dest) < GetScriptForDestination(b.dest));

source: gpt-6.1-sol (phase2-reviewer: general)

🔴 Blocking: Link addresstype.cpp into libdashkernel
src/Makefile.am:1281-1288

addresstype.cpp is included in libbitcoin_common_a_SOURCES but is absent from libdashkernel_la_SOURCES. The kernel library directly contains callers in Evolution, validation, key I/O, and txmempool that now reference the moved address symbols, while libdashkernel does not link libbitcoin_common. The linux64_nowallet CI link step consequently reports unresolved references to PKHash constructors, ExtractDestination, IsValidDestination, GetScriptForDestination, and related functions. Add addresstype.cpp to the kernel source list.

libdashkernel_la_SOURCES = \
  addresstype.cpp \
  kernel/bitcoinkernel.cpp \

source: gpt-6.1-sol (phase2-reviewer: general)

🟡 Suggestion: Pass the Platform funding destination directly to CRecipient
src/wallet/interfaces.cpp:496-497

CRecipient now represents a CTxDestination, but this call first converts the PKHash into a script and then implicitly wraps that script as CNoDestination. GetScriptForDestination still reconstructs the same output script, so transaction serialization is preserved, but the recipient loses its PKHash type and any recipient-level destination or validity handling will see it as a raw script. Pass the PKHash directly.

CRecipient{PKHash{funding_pubkey.value}, credit_amount,
                                               /*fSubtractFeeFromAmount=*/false, /*fPlatformTransfer=*/true}

source: muse-spark-1.3-contributor (phase1-reviewer: general)

🟡 Suggestion: Restore the omitted bitcoin#28246 fuzz-test transformation
src/test/fuzz/key.cpp:203-212

The current fuzz test still constructs PKHash(pubkey) directly and only checks script and address round-tripping. The upstream bitcoin#28246 merge transformation uses GetDestinationForKey(pubkey, output_type), checks the selected output type and destination validity, and verifies the destination through GetKeyForDestination. The corresponding helper and lookup APIs are present in this tree, so this upstream test hunk can be adapted rather than omitted.

source: gpt-6.1-sol (phase2-reviewer: general, backport-reviewer, dash-core-commit-history)

Review provenance

Source: reviewer 1: muse-spark-1.3-contributor (agent: phase1-reviewer, role: general); reviewer 2: gpt-6.1-sol (agent: phase2-reviewer, role: general); reviewer 3: gpt-6.1-sol (agent: phase2-reviewer, role: backport-reviewer); reviewer 4: gpt-6.1-sol (agent: phase2-reviewer, role: dash-core-commit-history); final verifier: gpt-6.1-sol (agent: sol-verifier, role: final-verifier)

  • Triage: critical by gpt-6.1-sol (effort low) — This is a large, intricate backport that changes critical consensus and storage surfaces, including block storage and chainstate handling in src/node/blockstorage.cpp and related deserialization and validation code.
  • Phase 1 reviewers: muse-spark-1.3-contributor — general (completed, effort xhigh); agent phase1-reviewer
  • Phase 1 model: muse-spark-1.3-contributor — not quota-gated; passed over gemini-3.8-flash-high (antigravity quota lookup failed), glm-5.3-flash (not used above high effort; tier asks max)
  • Single stage: Phase 1 and Phase 2 reviewed this head side by side, with no blocker gate between them (triage tier)
  • Fresh verifier: gpt-6.1-sol — final-verifier; agent sol-verifier
  • Phase 2 reviewers: gpt-6.1-sol — general (completed, effort xhigh); agent phase2-reviewer, gpt-6.1-sol — backport-reviewer (completed, effort xhigh); agent phase2-reviewer, gpt-6.1-sol — dash-core-commit-history (completed, effort xhigh); agent phase2-reviewer
🤖 Prompt for all review comments with AI agents
These findings are from an automated code review (PastaClaw). How to work through them:
- Verify each finding against the code; fix only what is real, as narrowly as the finding.
- If a finding is wrong, decline it on its thread in one or two sentences; the bot answers once and stops.
- To defer one, link a tracking issue on its thread (or reply asking the bot to file one).
- Suggestions don't block the merge, but most are worth fixing in this PR; judge each on its merits.
- Keep the PR's scope; don't grow it to satisfy hardening suggestions.
- Carried items were raised in an earlier round: read the thread first, and don't re-fix what you already fixed, declined or deferred there. Disputed and deferred items are already handled and are not listed.

In `src/wallet/spend.cpp`:
- [BLOCKING] src/wallet/spend.cpp:1111: Update the BIP69 comparator for the renamed recipient field
  CRecipient now stores its destination in dest, but this comparator still accesses the removed scriptPubKey member. The source-build CI logs show compilation failures at this exact line on the aarch64, Windows, and Linux builds. Compare the reconstructed scripts from the destinations instead.

In `src/Makefile.am`:
- [BLOCKING] src/Makefile.am:1281-1288: Link addresstype.cpp into libdashkernel
  addresstype.cpp is included in libbitcoin_common_a_SOURCES but is absent from libdashkernel_la_SOURCES. The kernel library directly contains callers in Evolution, validation, key I/O, and txmempool that now reference the moved address symbols, while libdashkernel does not link libbitcoin_common. The linux64_nowallet CI link step consequently reports unresolved references to PKHash constructors, ExtractDestination, IsValidDestination, GetScriptForDestination, and related functions. Add addresstype.cpp to the kernel source list.

In `src/addresstype.h`:
- [BLOCKING] src/addresstype.h:20: Initialize the script held by the default CNoDestination
  CNoDestination now contains a CScript, but its default constructor remains defaulted. GCC 14 reports that the prevector size inside that script may be uninitialized while destroying the default CTxDestination created in CWallet::IsSpentKey; the Linux source build promotes this diagnostic to an error. Explicitly value-initialize m_script so the compiler can establish that the contained prevector is initialized.

In `src/wallet/interfaces.cpp`:
- [SUGGESTION] src/wallet/interfaces.cpp:496-497: Pass the Platform funding destination directly to CRecipient
  CRecipient now represents a CTxDestination, but this call first converts the PKHash into a script and then implicitly wraps that script as CNoDestination. GetScriptForDestination still reconstructs the same output script, so transaction serialization is preserved, but the recipient loses its PKHash type and any recipient-level destination or validity handling will see it as a raw script. Pass the PKHash directly.

In `src/qt/transactiontablemodel.cpp`:
- [NITPICK] src/qt/transactiontablemodel.cpp:703: Use numeric zero-padding for the transaction date sort key
  The format uses %020s for the qint64 timestamp. tinyformat treats %s as stream string formatting, so the width is space-padding rather than zero-padding. Current timestamps happen to have the same digit count, but the sort key is not robust for timestamps with different widths. Use an integer conversion.

In `src/test/fuzz/key.cpp`:
- [SUGGESTION] src/test/fuzz/key.cpp:203-212: Restore the omitted bitcoin#28246 fuzz-test transformation
  The current fuzz test still constructs PKHash(pubkey) directly and only checks script and address round-tripping. The upstream bitcoin#28246 merge transformation uses GetDestinationForKey(pubkey, output_type), checks the selected output type and destination validity, and verifies the destination through GetKeyForDestination. The corresponding helper and lookup APIs are present in this tree, so this upstream test hunk can be adapted rather than omitted.

Comment thread src/addresstype.h
CScript m_script;

public:
CNoDestination() = default;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 Blocking: Initialize the script held by the default CNoDestination

CNoDestination now contains a CScript, but its default constructor remains defaulted. GCC 14 reports that the prevector size inside that script may be uninitialized while destroying the default CTxDestination created in CWallet::IsSpentKey; the Linux source build promotes this diagnostic to an error. Explicitly value-initialize m_script so the compiler can establish that the contained prevector is initialized.

Suggested change
CNoDestination() = default;
CNoDestination() : m_script{} {}

source: gpt-6.1-sol (phase2-reviewer: general, backport-reviewer, dash-core-commit-history)

return QString::fromStdString(rec->status.sortKey);
case Date:
return rec->time;
return QString::fromStdString(strprintf("%020s-%s", rec->time, rec->status.sortKey));

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💬 Nitpick: Use numeric zero-padding for the transaction date sort key

The format uses %020s for the qint64 timestamp. tinyformat treats %s as stream string formatting, so the width is space-padding rather than zero-padding. Current timestamps happen to have the same digit count, but the sort key is not robust for timestamps with different widths. Use an integer conversion.

Suggested change
return QString::fromStdString(strprintf("%020s-%s", rec->time, rec->status.sortKey));
return QString::fromStdString(strprintf("%020d-%s", rec->time, rec->status.sortKey));

source: muse-spark-1.3-contributor (phase1-reviewer: general)

@thepastaclaw thepastaclaw added the pastaclaw:changes-requested thepastaclaw's latest review requested changes label Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs rebase pastaclaw:changes-requested thepastaclaw's latest review requested changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants