Skip to content

log ping timeouts and track consecutive failures#609

Draft
Agent-Hellboy wants to merge 3 commits intoevalstate:mainfrom
Agent-Hellboy:_enhance_transport_tracking
Draft

log ping timeouts and track consecutive failures#609
Agent-Hellboy wants to merge 3 commits intoevalstate:mainfrom
Agent-Hellboy:_enhance_transport_tracking

Conversation

@Agent-Hellboy
Copy link
Copy Markdown
Contributor

@Agent-Hellboy Agent-Hellboy commented Jan 8, 2026

fixes #607

@evalstate
Copy link
Copy Markdown
Owner

Triage result

Human attention: ⚠️ Required
Recommendation: 🏁 escalate to a human
Human decision needed: confirm the intended ping-timeout handling behavior and approve the fix without this run’s behavioral validation

Quick read

This PR is aimed at issue #607: it makes MCP ping timeouts visible, counts consecutive failures, and escalates repeated timeouts into connection-reset behavior.

Intent

Improve MCP transport monitoring so ping timeouts are treated as real connection failures, with logging and reconnection after repeated failures.

Why

The reported problem is that the transport layer only handled generic connection errors, so ping-specific failures were not being tracked or escalated per the MCP guidance.

The code changes are right-shaped for that goal:

  • adds a shared ping failure tracker
  • resets the counter on successful traffic / keepalive activity
  • treats read/timeout errors as ping failures
  • emits diagnostic logging and a reset threshold

Codex review

Verdict: good_enough for the underlying bug shape, but this run could not establish the behavior end-to-end.

CI/CD

Blocked for this handoff step: this workspace did not expose a command execution path, so I could not run a focused repro or validate the fix behaviorally.

Recommendation

Please have a human confirm the design/behavioral expectations for ping timeout escalation and then proceed with validation or merge approval.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enhance transport_tracking against Error Handling for ping

2 participants