Skip to content

gui: Wait for a wallet choice and list new wallets as the CLI does - #219

Open
BenWestgate wants to merge 3 commits into
claude/project-thread-p319g5from
claude/project-thread-pg6lr5
Open

BenWestgate wants to merge 3 commits into
claude/project-thread-p319g5from
claude/project-thread-pg6lr5

Conversation

@BenWestgate

Copy link
Copy Markdown
Owner

Requested by Ben · project thread

Stacked on #217 (the Bails pin line). One commit.

Bug

On "Which wallet should hold your keys?" with only the create row, the row drew as a lone checkbox. Unticking it left nothing chosen and Continue raised StopIteration in _selected.

Change

  • _radio_group groups every row under a hidden leader, so even one row is a radio that can't be unticked. Nothing is pre-chosen; the page's Continue stays disabled until a choice. Applies to the network, card-layout and wallet pages.
  • Wallet page: "Check again" is gone. The page asks Core every second while it is visible, as the CLI waits for a new wallet, and keeps the chosen wallet by name across a refresh.
  • work.run queues jobs behind one lock instead of failing "busy", so an import waits for an in-flight poll.

GUI lines: 2,045 (budget < 2,050; was 2,047).

Tests

  • python -m pytest under Xvfb: 1,066 passed. Two new GTK tests fail on the parent commit.
  • tools/gui_walkthrough.py under Xvfb: every check passed.

Does not cherry-pick cleanly onto gui-reviewability-v1; there, #66 covers the polling.


Generated by Claude Code

Bitcoin Core resolves an import timestamp of "now" to its tip's median
time. On an offline signer that never synced, that is the genesis block,
so every new wallet was born in 2009, and the watch-only copy Bails
exports from it asks the online node to rescan from genesis, which a
pruned node cannot do.

A new wallet now takes this computer's clock, a day early like a
recorded creation date, so a clock running up to a day fast cannot skip
its first payments. Restores keep the recorded date.

On a Core 32.1 regtest signer at genesis, the descriptors were dated
1296688602 (genesis) before and the clock less a day after; the signer
still found a payment from blocks it synced later.

Claude-Session: https://claude.ai/code/session_01N8jLK61uohaW6W7Y8AHnMb
@BenWestgate BenWestgate self-assigned this Nov 9, 2026
@BenWestgate
BenWestgate marked this pull request as ready for review November 9, 2026 18:42
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-17T20:54:12.755920Z 7a0cf7a New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@BenWestgate

Copy link
Copy Markdown
Owner Author

Can we move the polling to the API so we dont duplicate code between the CLI and GUI?

@BenWestgate
BenWestgate added this pull request to stack #204 November 10, 2026 04:55
A list with one row drew a lone checkbox. Unticking it left nothing
chosen, and Continue then raised StopIteration in _selected. Group every
row under a hidden leader so even one row is a radio that cannot be
unticked, start with nothing chosen, and keep Continue disabled until a
choice is made.

The wallet page asked Bitcoin Core again only on "Check again". Poll
once a second instead, as the CLI waits for a new wallet, keeping the
chosen wallet by name across a refresh. Only one poll runs at a time,
and work.run queues jobs behind one lock, so an import waits for a poll
rather than failing as busy.

BitcoinCore._eligible_wallets(names) looks once, without waiting, at
which of the given wallets are eligible and returns their encryption and
lock state. The CLI's menu and its wait for a new wallet use it with the
names they already fetched, so the CLI asks Core exactly what it asked
before. wallet_setup.eligible() is now an adapter over it.

Claude-Session: https://claude.ai/code/session_01N8jLK621Vh9wiv9ZntctSG
@BenWestgate
BenWestgate force-pushed the claude/project-thread-pg6lr5 branch from b5ef808 to 7a0cf7a Compare November 17, 2026 20:52

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant