Repository navigation
gui: Let a mistyped passphrase be typed again - #220
Draft
BenWestgate wants to merge 1 commit into
Draft
BenWestgate wants to merge 1 commit into
BenWestgate wants to merge 1 commit into
Conversation
A wrong wallet passphrase ended on the "Stopped" page, whose buttons both dropped the seed: after a new backup, "Restore my wallet" meant entering every card again. The command line never loses the seed this way. Once cards exist, a failed Bitcoin Core step now goes back to the page that asked, with the error in a dialog, so the operator just tries again. A spinner page or home is never gone back to; those still stop. The unlock page shrinks to one passphrase field and one Unlock button, and fits without scrolling. An unlock done in Bitcoin Core's console is noticed by polling, as the command line waits, which replaces the "I unlocked it myself" button and the expander. Claude-Session: https://claude.ai/code/session_01N8jLK5fxFGLYhRkgPfn86t
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Ben · project thread
Stacked on #217, which is the line Ben's VM runs. It's one commit, and it cherry-picks onto
gui-reviewability-v1, where the unlock page is the same.Bug. A wrong wallet passphrase ended on the "Stopped" page. Both of its buttons dropped the seed, so after a new backup, "Restore my wallet" meant typing every card in again. The CLI never asks for the passphrase, so it can't fail this way.
Change.
_then: once cards exist (CARDS_SAFE), a failed Core step goes back to the page that asked, which still holds the seed. The error is shown in a dialog with a "Try again" button. It never goes back to home or to a spinner page (_workingmarks those); those cases still stop as before. This also covers listing wallets, creating one, the fingerprint check and imports.work.watch: while the page is in front, it asks Core every 2 s, off the main loop, whether the wallet is unlocked. This is how the CLI waits. Once Core says yes, it imports with no passphrase, so the library relocks afterwards just as in the CLI. It fires only once, so a failed import can't loop.wallet_setup.require_unlockedis replaced byunlocked().Checked.
python -m pytest: 660 passed, 2 skipped. The bip32-oracle modules can't be collected here because the proxy blocks the pinned tarball, so CI covers those. ruff and mypy (src) are clean. The GUI is 2,049 lines, under this line'sBUDGET = 2050. Not run in GTK here (no libadwaita in the container), so it still needs a VM check.Needs Ben's security review: it touches the import/relock path.
Generated by Claude Code