diff --git a/selective-vpn-gui/dashboard_controller.py b/selective-vpn-gui/dashboard_controller.py index 82d655f..a8570c0 100644 --- a/selective-vpn-gui/dashboard_controller.py +++ b/selective-vpn-gui/dashboard_controller.py @@ -669,6 +669,10 @@ class DashboardController: dns_cooldown_skips = int(pairs.get("dns_cooldown_skips", 0)) live_batch_target = int(pairs.get("live_batch_target", 0)) live_batch_deferred = int(pairs.get("live_batch_deferred", 0)) + live_batch_p1 = int(pairs.get("live_batch_p1", 0)) + live_batch_p2 = int(pairs.get("live_batch_p2", 0)) + live_batch_p3 = int(pairs.get("live_batch_p3", 0)) + live_batch_nxheavy_skip = int(pairs.get("live_batch_nxheavy_skip", 0)) r_checked = int(pairs.get("timeout_recheck_checked", 0)) r_recovered = int(pairs.get("timeout_recheck_recovered", 0)) @@ -683,7 +687,8 @@ class DashboardController: f"(live={unresolved_live}, suppressed={unresolved_suppressed}) | " f"quarantine_hits={q_hits} | dns_timeout={dns_timeout} " f"| cooldown_skips={dns_cooldown_skips} | attempts={dns_attempts} " - f"| live_batch={live_batch_target} deferred={live_batch_deferred}" + f"| live_batch={live_batch_target} deferred={live_batch_deferred} " + f"(p1={live_batch_p1}, p2={live_batch_p2}, p3={live_batch_p3}, nx_skip={live_batch_nxheavy_skip})" ) recheck_text = ( f"Timeout recheck: checked={r_checked} recovered={r_recovered} " @@ -693,6 +698,12 @@ class DashboardController: color = "green" if unresolved < 4000 else ("#b58900" if unresolved < 10000 else "red") if dns_timeout > 500 and color == "green": color = "#b58900" + if live_batch_p3 > 0 and (live_batch_p1+live_batch_p2) > 0: + ratio = float(live_batch_p3) / float(live_batch_p1 + live_batch_p2 + live_batch_p3) + if ratio > 0.8: + color = "#b58900" if color == "green" else color + if ratio > 0.95: + color = "red" recheck_color = "green" if r_still_timeout <= 20 else ("#b58900" if r_still_timeout <= 100 else "red") return RoutesResolveSummaryView( available=True,