Repository navigation
Description
Summary
The qbit-qt create-wallet progress dialog is application-modal and has no Cancel button, but its window close affordance remains available. Closing the dialog deletes the only progress surface and removes modality, while the underlying CreateWalletActivity continues creating the wallet.
There is no cancellation connection from the dialog to the activity. If creation succeeds, the completed wallet is still added and can become the active GUI wallet.
Impact
Closing what appears to be the active create-wallet operation can still:
- create and persist the wallet;
- load it into the process;
- register it in startup state; and
- switch qbit-qt to the newly created wallet later.
This makes the displayed outcome disagree with durable wallet state and user intent. It is not a demonstrated key-confidentiality failure.
Steps to reproduce
Use a latch-controlled wallet creation operation:
- Start creating a wallet and pause the worker while the progress dialog is visible.
- Close the progress window using its title-bar control or Escape.
- Observe that the progress surface disappears and the main interface becomes available.
- Release the worker.
- Observe that wallet creation continues and the completed wallet is added or selected.
- Restart qbit-qt and inspect the wallet directory, loaded-wallet list, startup settings, and active-wallet selection.
Relevant code
showProgressDialog()setsWA_DeleteOnClose, removes the Cancel button, but does not connect closure to cancellation.CreateWalletActivityruns creation on its worker and emitscreatedafter success.BitcoinGUIselects wallets emitted by the activity.
Desired outcome
Adopt one explicit and truthful contract:
- prevent the progress window from closing while a non-cancellable operation is running;
- implement cancellation up to a clearly defined durable boundary; or
- explicitly offer “Continue in background,” retain accessible status, and avoid an unexpected active-wallet switch.
Closing the only progress surface must not be presented as cancellation when creation will continue unchanged.
Suggested tests
Add latch-controlled Qt coverage for close and Escape:
- before database creation;
- during encryption and descriptor setup;
- after durable creation but before model adoption; and
- immediately before the activity emits
created.
For each boundary, assert the resulting listwalletdir, listwallets, startup setting, active-wallet selection, and restart state match the outcome shown to the user.
Version and platform
- Source-inspected on
mainat7e48b45f2a8e75268fd1fd44d0091a4bdde2377e. - Also applies to
1.0.0at68a12571bcb56597c4865abce474a6cc3d356fc3; the relevant files are identical. - Window-close behavior should be verified across supported Qt platforms and window managers.
Activity