Skip to content

fix(lsp): classify initialize-request write failures with stderr - #270

Merged
ScriptedAlchemy merged 1 commit into
masterfrom
fix/lsp-initialize-write-classification
Jul 4, 2026
Merged

fix(lsp): classify initialize-request write failures with stderr#270
ScriptedAlchemy merged 1 commit into
masterfrom
fix/lsp-initialize-write-classification

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Fixes the Windows CI flake in broker_marks_initialize_exit_crashed_without_message_classification (seen on release PR #267, run 28690268431, whose diff was changelog-only).

Mechanism: a server that exits immediately can fail the initialize request write (broken pipe) before the initialize response wait begins. That write used a bare ?, bypassing the kill + captured-stderr enrichment that the response path has — so the error lost the server's actual crash reason ("unknown binary ...") and the assertion failed. On Linux the write usually lands in the pipe buffer first, which is why only Windows-under-load flakes.

Fix at the mechanism level rather than loosening the test: the request-write failure now routes through the same stderr-enriched classification, so the crash reason is deterministic on both platforms. LSP suite 24/24 locally, strict clippy clean.

🤖 Generated with Claude Code

When an LSP server dies immediately after spawn, the initialize
*request* write can fail with a broken pipe before the initialize
*response* wait ever starts — on Windows under CI load this raced often
enough to flake broker_marks_initialize_exit_crashed_without_message_
classification on a changelog-only release PR (run 28690268431): the
bare write error propagated without the captured stderr, so the
crash reason ("unknown binary ...") was dropped. Route the request-write
failure through the same kill + stderr-enrichment path as the response
failure, making the classification deterministic on both platforms.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@changeset-bot

changeset-bot Bot commented Jul 4, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 2fa2391

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@ScriptedAlchemy
ScriptedAlchemy merged commit 80a9e16 into master Jul 4, 2026
14 checks passed
@ScriptedAlchemy
ScriptedAlchemy deleted the fix/lsp-initialize-write-classification branch July 4, 2026 01:45
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