fix(chat): classify resume-on-reopen errors + de-poison thread (#3714)

Classifies resume-on-reopen failures (session_expired / network / poisoned-history) instead of the generic catch-all, and evicts a 400-poisoned warm session so the thread self-heals. Closes #3714.
This commit is contained in:
sanil-23
2026-06-17 13:14:03 +05:30
committed by GitHub
parent c818f026cb
commit a1b7c29338
5 changed files with 420 additions and 17 deletions
@@ -328,10 +328,12 @@ async fn web_round19_covers_classifier_variants_and_cancel_cleanup() {
assert_eq!(budget.error_type, "budget_exhausted");
assert_eq!(budget.source, "openhuman_billing");
// #3714: a DNS / transport drop now classifies as the dedicated `network`
// arm (was the generic `inference` catch-all), still retryable.
let network = web_test_support::classify_error_for_test(
"request error: dns error while trying to connect",
);
assert_eq!(network.error_type, "inference");
assert_eq!(network.error_type, "network");
assert!(network.retryable);
web_test_support::set_forced_run_chat_task_error_for_test(Some(