forceDeleteWallet method
FORCE-complete a deleteWallet for a wallet that cannot be opened and whose
custody key is ALREADY GONE — the #251 escape out of a non-retryable
OnboardingFailed (needsRecovery). The plain deleteWallet fails CLOSED
(keystoreInconsistent) when its verify-real-sever guard finds no key to
sever; this SKIPS that guard and removes the unreadable remnant's files. It
MUST be called DELIBERATELY — only AFTER a plain deleteWallet reported
keystoreInconsistent, with the device UNLOCKED (the SDK wipe_force
contract: forcing past the guard could otherwise delete the wrong files). The
seed is NOT on the device — funds are recovered from the recovery phrase the
user then enters — so removing the remnant loses no money. THROWS on a genuine
filesystem fault (the caller re-probes to a still-escapable failure, never a
dead-end). After success this instance owns no wallet — the caller routes to
the restore form.
Implementation
@override
Future<void> forceDeleteWallet() async {
forceDeleteCount++;
if (failForceDelete != null) throw failForceDelete!;
exists = false; // the unreadable remnant is force-removed — gone from disk
}