{"repo":"NousResearch/hermes-agent","public_id":"70773","display_label":"Shared OpenAI client closed by streaming watchdog","summary":"These issues and fixes concern a bug where a streaming watchdog closes the shared OpenAI client from a non-owner thread, causing file-descriptor recycling that corrupts SQLite via TLS. The problem affects both the built-in and custom OpenAI-compatible providers.","subsystem":null,"counts":{"members":4,"open_issues":0,"open_issues_distinct":0,"open_prs":0,"closed_issues":1,"merged_prs":1,"attempt_prs":2},"landed_fix":{"status":"merged_to_main","basis":"structural","pr":70993,"merged_at":"2026-07-24T23:04:49+00:00"},"resolution":{"state":"resolved","by":"pr-70993"},"freshness":{"state":"verified","last_verified_at":"2026-07-24T23:04:49+00:00","is_stale":false},"grouping":{"backbone":"STRUCTURAL_SPANNING","link_density":0.5},"fix_edges":[{"issue_number":70773,"pr_number":70993,"tier":"verified","basis":"closing_ref","confidence":0.95,"recoverable_from_timeline":true,"pr_merged_at":"2026-07-24T23:04:49+00:00"}],"members":[{"kind":"issue","number":70773,"title":"Custom OpenAI-compatible provider still corrupts SQLite via TLS FD reuse in v0.18.2 — streaming stale watchdog closes shared client pool from non-owner thread","url":null,"state":"closed"},{"kind":"pr","number":70802,"title":"fix(agent): prevent shared OpenAI client FD-recycle corruption from stale stream watchdog","url":null,"state":"closed","close_reason":{"refs":[{"kind":"pr","value":"#70993","number":70993},{"kind":"pr","value":"#70773","number":70773}],"category":"merged_via","implication":"superseded"},"merged":false},{"kind":"pr","number":70993,"title":"fix(agent): stop cross-thread close of the shared OpenAI client (TLS FD-recycle SQLite corruption)","url":null,"state":"merged","close_reason":{"category":"merged"},"merged":true,"is_fix_pr":true,"fix_tier":"verified","files_changed":["agent/agent_runtime_helpers.py","agent/chat_completion_helpers.py","run_agent.py","tests/run_agent/test_70773_shared_client_fd_corruption.py","tests/run_agent/test_primary_runtime_restore.py","tests/run_agent/test_run_agent.py","tests/run_agent/test_run_agent_codex_responses.py"]},{"kind":"pr","number":71105,"title":"fix(streaming): never close OpenAI shared client from watchdog","url":null,"state":"closed","close_reason":{"refs":[{"kind":"pr","value":"#70993","number":70993},{"kind":"pr","value":"#70773","number":70773}],"category":"implemented_elsewhere","implication":"superseded"},"merged":false}],"trust":{"default_tier":"verified","includes_suggested":false}}