Skip to content

Retry transient TLS network failures - #1369

Draft
cursor[bot] wants to merge 2 commits into
mainfrom
cursor/out-3956-cursor-automated-triage-response-f0f7
Draft

Retry transient TLS network failures#1369
cursor[bot] wants to merge 2 commits into
mainfrom
cursor/out-3956-cursor-automated-triage-response-f0f7

Conversation

@cursor

@cursor cursor Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Changes

  • Add transient network error detection for Node/undici TLS disconnects such as Client network socket disconnected before secure TLS connection was established.
  • Reuse the shared retry wrapper for webhook dispatch fetches so transient socket resets get retried there too.
  • Add focused unit coverage for retrying status-less TLS/network failures while leaving unrelated errors non-retryable.

Testing Criteria

  • yarn test src/app/api/core/utils/withRetry.test.ts --runInBand passed.
  • yarn lint:check passed with existing React hook/compiler warnings only.
  • yarn tsc was attempted; it still fails before these changes on existing missing SVG module declarations from src/icons/index.ts.

Notes

  • Linear/Sentry MCP access was unavailable (Linear returned 401 and Sentry requires auth), so the investigation used the trigger metadata, repository Sentry config (project: 'tasks'), and code paths for outbound network calls.

Impact & Surface Area of Change

  • Affects shared Copilot API retry behavior for HTTP retries plus transient network failures with known retryable network codes (ECONNRESET, ETIMEDOUT, EAI_AGAIN) and the exact TLS disconnect message.
  • Webhook dispatch keeps its existing swallow/log behavior after retries are exhausted; successful transient retry prevents one-off TLS resets from surfacing as failures.
Open in Web View Automation 

cursoragent and others added 2 commits July 2, 2026 16:17
Co-authored-by: Neil Raina <makeitraina@users.noreply.github.com>
Co-authored-by: Neil Raina <makeitraina@users.noreply.github.com>
@linear-code

linear-code Bot commented Jul 2, 2026

Copy link
Copy Markdown

OUT-3956

@vercel

vercel Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
tasks-app Ready Ready Preview, Comment Jul 2, 2026 4:20pm

Request Review

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.

1 participant