From bf092576d294d54a57bb18531b6bc6d84d0420b3 Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Mon, 23 Nov 2026 23:35:35 -0700 Subject: names: float consolidation skips a merge that can't pay for its round. Once upkeep ran again (f27c49c) the 92 small coins tripped consolidation, whose 64 smallest came to 259 sat against a 301-sat round fee: refused, and asked again every minute. Sends gather largest-first, so dust never decides whether one fits; the merge now waits until the coins it would take clear the fee and the 330-sat floor. Checked on the live float state (skip: true); names tests pass. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01VMan6Upic5L6MMJzkTn8zg --- names/server.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'names/server.js') diff --git a/names/server.js b/names/server.js index 6bbec01..600b12a 100644 --- a/names/server.js +++ b/names/server.js @@ -1035,9 +1035,13 @@ async function consolidateFloat() { if ((fwd.state.actions || []).some((a) => !['done', 'failed'].includes(a.step))) return; const small = (await smallCoins()).slice(0, CONSOLIDATE_MAX); if (small.length < 2) return; + const sat = small.reduce((n, v) => n + v.amountSat, 0); + // a heap of dust can't pay for its own round (64 coins, 259 sat, 301 sat + // fee, 2026-11-24 — refused every minute once upkeep ran again); sends + // gather largest-first, so dust never decides whether one fits anyway + if (sat - fwd.refreshFee(small, await fwd.chain.tipHeight()) < 330) return; consolidating = true; try { - const sat = small.reduce((n, v) => n + v.amountSat, 0); log(`float consolidate: merging ${small.length} coins (${sat} sat)`); await fwd.refresh(small.map((v) => v.id)); log(`float consolidate: submitted — it settles once the round confirms`); -- cgit v1.2.3