Skip to content

Commit a5ae938

Browse files
Herklosclaude
andcommitted
[Node] propagate auth errors from init_sync_client_with_passphrase
Swallowing WalletNotFoundError / InvalidPassphraseError hid failures from callers. Let authenticate() raise directly so API routes can map to the correct HTTP status. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
1 parent e41dfa2 commit a5ae938

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

octobot/community/authentication.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -709,11 +709,7 @@ def init_sync_client_with_passphrase(self, passphrase: str) -> None:
709709
self.logger.debug("No wallets configured, cannot initialize sync client")
710710
return
711711
admin = next((w for w in wallets if w.get("is_admin")), wallets[0])
712-
try:
713-
self._wallet_backend.authenticate(admin["address"], passphrase)
714-
except (KeyError, ValueError) as e:
715-
self.logger.error(f"Cannot init sync client with passphrase: {e}")
716-
return
712+
self._wallet_backend.authenticate(admin["address"], passphrase)
717713
self.init_sync_client_for_wallet(admin["address"])
718714

719715
def auto_init_sync_client(self) -> bool:

0 commit comments

Comments
 (0)