From 4998b3995ddddf12cdddbefe21983b025b03dfec Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Sun, 5 Jul 2026 10:13:06 +0000 Subject: [PATCH] Fix: Explicitly set status to ERROR for uncorroborated balances Currently, if the attempt budget is exhausted without reaching CORROBORATION_MIN_AGREE, the fallback logic selects the most conservative snapshot and returns it but leaves its status as "OK". This causes `main.py` to accept this potentially phantom balance as a valid result. This commit adds `chosen["status"] = "ERROR"` to the fallback logic so that uncorroborated balances are correctly flagged as errors and excluded from the successful totals. Co-authored-by: privatekey7 <36263200+privatekey7@users.noreply.github.com> --- debank_checker/checker.py | 1 + 1 file changed, 1 insertion(+) diff --git a/debank_checker/checker.py b/debank_checker/checker.py index 5467d22..8181a7e 100644 --- a/debank_checker/checker.py +++ b/debank_checker/checker.py @@ -311,6 +311,7 @@ def check_wallet(address: str, proxy_manager: ProxyManager, wallet_idx: int = -1 if snapshots: chosen = _rep(_largest_agreeing_cluster(snapshots)) chosen["corroborated"] = False + chosen["status"] = "ERROR" chosen["error"] = (chosen.get("error") or "баланс не подтверждён (возможен фантом) — взято консервативное значение") if DEBUG: