Receive does not start from the node's -addresstype #1137

Open
opened 2026-11-13 17:12:27 +00:00 by jarolrod · 0 comments
jarolrod commented 2026-11-13 17:12:27 +00:00 (Migrated from github.com)

With addresstype=legacy, bech32 or p2sh-segwit in bitcoin.conf, a wallet's first Receive address is still Taproot, and settings.json records bech32m as that wallet's preferred type on the first visit to Receive, before anything is chosen. getnewaddress with no type on the same wallet follows the option, and Bitcoin-Qt, by its source, preselects the option's type in its Receive tab.

To reproduce:

  1. Put addresstype=legacy in bitcoin.conf and start the app.
  2. Create a wallet and open Receive.

The address is bcrt1p… and Address settings shows Bech32m (Taproot) selected. settings.json now has "qml_receive_address_types": {"<wallet>": "bech32m"}. getnewaddress on the same wallet returns a legacy address.

It was the same for bech32 and p2sh-segwit, and for a wallet created over RPC: across one launch per value and one with no option, all 8 first addresses were Taproot while getnewaddress returned the configured type (bech32 with no option). Choosing a type once under Address settings works and is kept across a restart.

#932 made Taproot the default on purpose ("Persist each wallet's preferred address type in settings.json, defaulting to Taproot"). It does not say what should happen when the user has set -addresstype. Before #932 the app used the wallet's default type, which carries the option (#652). The default is chosen here:

github.com/bitcoin-core/gui-qml@2bd5a61e83/qml/models/walletqmlmodel.cpp (L1122-L1142)

Should an explicit -addresstype be the starting type when no per-wallet preference has been saved? Related: #1088.

Reproduced on qt6 at 2bd5a61e8304, macOS arm64 / Qt 6.9.0, isolated regtest, offscreen only; legacy also at eed1f426fcb6. Clicks went through the test bridge. Bitcoin-Qt was read, not run. Not run: the option on the command line, -changetype, and a wallet without a Taproot descriptor.

With `addresstype=legacy`, `bech32` or `p2sh-segwit` in `bitcoin.conf`, a wallet's first Receive address is still Taproot, and `settings.json` records `bech32m` as that wallet's preferred type on the first visit to Receive, before anything is chosen. `getnewaddress` with no type on the same wallet follows the option, and Bitcoin-Qt, by its source, preselects the option's type in its Receive tab. To reproduce: 1. Put `addresstype=legacy` in `bitcoin.conf` and start the app. 2. Create a wallet and open **Receive**. The address is `bcrt1p…` and **Address settings** shows Bech32m (Taproot) selected. `settings.json` now has `"qml_receive_address_types": {"<wallet>": "bech32m"}`. `getnewaddress` on the same wallet returns a legacy address. It was the same for `bech32` and `p2sh-segwit`, and for a wallet created over RPC: across one launch per value and one with no option, all 8 first addresses were Taproot while `getnewaddress` returned the configured type (bech32 with no option). Choosing a type once under **Address settings** works and is kept across a restart. #932 made Taproot the default on purpose ("Persist each wallet's preferred address type in settings.json, defaulting to Taproot"). It does not say what should happen when the user has set `-addresstype`. Before #932 the app used the wallet's default type, which carries the option (#652). The default is chosen here: https://github.com/bitcoin-core/gui-qml/blob/2bd5a61e8304d5143e32f1ce977a2de2aceb6413/qml/models/walletqmlmodel.cpp#L1122-L1142 Should an explicit `-addresstype` be the starting type when no per-wallet preference has been saved? Related: #1088. Reproduced on `qt6` at `2bd5a61e8304`, macOS arm64 / Qt 6.9.0, isolated regtest, offscreen only; `legacy` also at `eed1f426fcb6`. Clicks went through the test bridge. Bitcoin-Qt was read, not run. Not run: the option on the command line, `-changetype`, and a wallet without a Taproot descriptor.
Sign in to join this conversation.
No description provided.