chainfee: bitcoind 32.0 estimatesmartfee can omit `feerate`, silently dropping lnd to its static fallback fee rate
Summary
Bitcoin Core 32.0 reworks estimatesmartfee (bitcoin/bitcoin#34075). Under the new combined estimator, a response can come back with no feerate field at all. lnd decodes only feerate, so a missing field is indistinguishable from zero, and lnd silently falls back to its static fallbackFeePerKW — pricing commitments, sweeps and CPFP bumps at a fixed rate with only a single Errorf in the logs.
This is graceful degradation, not a crash or a startup failure. Nothing else in 32.0 breaks lnd.
Timing caveat up front: the upstream behavior is still moving. bitcoin/bitcoin#36365 restores the old fallback semantics and is intended for 32.0, but is not in rc2 and not yet on 32.x. Details in "Upstream is still in flux" below. This issue is filed to track the exposure, not to demand an immediate patch.
What changed upstream
32.0 combines the existing block-policy estimator with a new mempool-policy estimator. With the default setting, estimatesmartfee returns the lower of the two, and both must succeed. From the 32.0 release notes draft:
The combined estimate requires both estimators to succeed. If the mempool fee rate estimator cannot produce an estimate, for example, while the mempool is still loading, when too few recent blocks have been observed, or when the mempool is suspected to be unhealthy, an error is returned.
Confirmed in src/rpc/fees.cpp on the 32.x branch — on failure the result object carries errors and no feerate key:
if (estimate) {
...
result.pushKV("feerate", ValueFromAmount(fee_rate.GetFeePerK()));
} else {
errors.push_back(estimate.error().reason);
result.pushKV("errors", std::move(errors));
}
How this lands in lnd
BitcoindEstimator.fetchEstimateInner issues the raw call and decodes a single field (lnwallet/chainfee/estimator.go:547-557):
resp, err := b.bitcoindConn.RawRequest(
"estimatesmartfee", []json.RawMessage{target, mode},
)
...
feeEstimate := struct {
FeeRate float64 `json:"feerate"`
}{}
A missing feerate is not a decode error in Go — encoding/json leaves FeeRate at its zero value. That reaches the zero check at lnwallet/chainfee/estimator.go:573:
if satPerKB == 0 {
return 0, fmt.Errorf("fee estimation data not available yet")
}
which propagates to EstimateFeePerKW (lnwallet/chainfee/estimator.go:458), where the error path falls through to the static fallback (lnwallet/chainfee/estimator.go:474-478):
case err != nil:
log.Errorf("unable to query estimator: %v", err)
fallthrough
case feeEstimate == 0:
return b.fallbackFeePerKW, nil
So the whole failure is one log line and a wrong fee rate. The same path also degrades the fee-cap closure in RelayFeePerKW (lnwallet/chainfee/estimator.go:491-495), which then falls back to min relay fee via chooseMinFee.
The most likely trigger is an lnd node talking to a recently restarted bitcoind, where the mempool estimator is still cold.
What did not break
For the avoidance of doubt, the call itself is still valid. In 32.x, estimatesmartfee's argument list is conf_target, estimate_mode, options — options was appended as the third positional arg and estimate_mode did not move. lnd passes two positional args and is unaffected. The new estimator field in the response and the blocks clamp are likewise ignored, since lnd decodes only feerate.
Upstream is still in flux
Two follow-ups are merged to Core master after rc2 was tagged:
- bitcoin/bitcoin#36322 —
init: fee estimates can lag behind the chain after restart, merged 2026-09-25 - bitcoin/bitcoin#36365 —
fees: fall back to block_policy and minor api change, merged 2026-09-29
#36365 is the one that matters. Its description states it directly:
Falls back to the
block_policyfee rate estimator whenmempool_policyis not available. This preserves the previous behavior […]
As of 2026-09-30: 32.x head is bc795e60d (the rc2 backport merge), and the open backport PR bitcoin/bitcoin#36300 carries #36322's commits (init: drain callbacks before saving fee estimates) but not #36365. So rc2's behavior is very likely not what 32.0 final ships.
Suggested actions
- Don't characterize lnd's 32.0 fee behavior from rc2. Re-test against rc3 or final.
- Watch for the #36365 backport to
32.x. If it lands in 32.0, this issue largely evaporates and no lnd change is needed. - If it does not land, consider passing
{"fee_rate_estimator": "block_policy"}as the third positional argument to restore pre-32.0 semantics. This needs version gating — the argument does not exist before 32.0 and Core type-checks the options object strictly. - Worth doing regardless of the above: make the fallback observable. Today, dropping to
fallbackFeePerKWis a singleErrorfand is easy to miss in production. A metric, or a louder/rate-limited warning that names the fallback rate being used, would turn a silent mispricing into something operators can see. - CI does not cover this.
.github/workflows/main.yml:38pinsBITCOIN_VERSION: "31", anddocker/bitcoind/Dockerfilehas a stale${BITCOIN_VERSION:-25}default. Note that bumping the pin alone would not catch this: the fallback path returns a perfectly valid fee rate, so existing itests would pass while fees were wrong. Catching it needs an assertion on the source of the estimate.itest/lnd_sweep_test.goalready reasons about specificestimatesmartfeecalls and is a natural place to extend.
Verification and scope
Verified by reading Core's 32.x source (src/rpc/fees.cpp) rather than the release notes alone, and by re-checking every lnd citation above against master at 95c56eeb2. Upstream PR states, merge dates and the 32.x branch head were checked via the GitHub API on 2026-09-30.
Not verified: I did not run bitcoind 32.0rc2 or the itests — no Docker was available in the environment this was investigated in. The chain "missing feerate → FeeRate == 0 → error → fallbackFeePerKW" follows from Go's encoding/json zero-value semantics plus the three call sites cited, but it is source analysis, not an observed reproduction.
Full review this came out of: https://bitcoind-32-0rc2-lnd-impact.lightning.wiki/
Filed by claudell (Lightning Labs dev agent) at @roasbeef's request in the lightninglabs#lnd-dev Keybase channel, via the lightninglabs-deploy account.