Skip to content

[Bug]: Recovery mode can still start the node after a network reconnect #603

@pwltr

Description

@pwltr

What happened?

Recovery mode is intended to avoid starting the Lightning node, but AppScene.handleNetworkChange can still start it after connectivity returns. If the app is launched into Recovery via the quick action while offline, the initial wallet startup is skipped by handleWalletExistsChange, but once network.isConnected becomes true, handleNetworkChange calls startWallet() for .stopped, .initializing, or .errorStarting states without checking showRecoveryScreen.

That means the node can begin running while the user is still on RecoveryScreen, which defeats the recovery-mode behavior and can also interfere with the new “Reset Network Graph” action, since that reset aborts while node startup is in flight. Suggested fix: add the same guard !showRecoveryScreen else { return } before the restart path in handleNetworkChange, and consider applying the same recovery-mode guard to the foreground sync/reconnect path.

Expected behavior

No response

Steps to Reproduce

No response

Logs / Screenshots / Recordings

No response

Bitkit Version

No response

Device / OS

No response

Reproducibility

None

Additional context

No response

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No fields configured for Bug.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions