Repository navigation
Compile item edits reload the owning compiler directly, not via the file watcher (Windows F# add-file hover) - #613
Merged
Conversation
…e, so the F# compiler reloads and owns the new file even when the platform watcher misses the host's own write
MelbourneDeveloper
enabled auto-merge (squash)
November 19, 2026 20:28
MelbourneDeveloper
added a commit
that referenced
this pull request
Nov 19, 2026
…mpt (Linux debug-inspection wedge) (#614) ## TLDR The 20-attach reliability test (added in #607) stops wedging Linux `debug-inspection`. Each attempt now attaches to its own fresh process and pauses the session that attach started. ## Details - **Failure** (#613, Linux `debug-inspection`): attempt 2's `stopDebuggee` timed out after 45 s. The stuck session then failed every later suite in the chunk, 12 failures in all. - **Mechanism, from the uploaded debugger trace:** - Attempt 1 attached, paused and detached in 0.2 s. - Attempt 2's attach was accepted, but no `pause` was ever sent. `startAttached` returns `vscode.debug.activeDebugSession`, which still named attempt 1's ending session. `pauseAttached` polled `threads` on that dead session until its 60-second limit. - Meanwhile the fixture's 30-second `wait` ran out. The process exited (`exited` code 0 at +29 s), and the session never settled in time. - Separately, 20 attaches to ONE 30-second fixture cannot fit on a slow runner: the attaches took 15 s locally, but CI is slower. - **Fix** (test only, no product change): - Every attempt starts a fresh fixture process. After the detach the test asserts that process is still alive, then kills it. - The attempt's session comes from `DebugSessionRecorder`, by its start index, never from `activeDebugSession`. - New end-of-test assertions: exactly 20 sessions started, and every one ended. ## How Do The Automated Tests Prove It Works? - `debug-attach-reliability-e2e.test.ts` *at least 19 of 20 attaches pause a live process, and every detach leaves it running* passes locally: 20/20 in 21 s, with every pause stop recorded and a clean session. - `debug-attach-e2e.test.ts` still passes (5 tests). - On this PR, Linux `debug-inspection` runs the test after the rest of the chunk, at CI speed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TLDR
Adding an F# file from the Solution Explorer now reloads the F# project right away. Before, the reload waited for the file watcher to notice the host's own
.fsprojwrite; on Windows it sometimes didn't, and the new file stayed unowned, with no hover or diagnostics.Details
workspaceleg failed on Test Explorer fsharp tag from the project's language (#604), 20-attach reliability test, unpredictable sidecar endpoints #607, NuGet audit policy evaluates like MSBuild: last unconditional assignment, project over props #609 and Debug Stop suite waits for earlier runs' terminals to close before counting its own #612 in Solution Explorer — Add F# Source File: project node: adds .fs before the last Compile item and FCS owns it. A hover on the new file stayed[]for the test's 90-second polling limit. Each failure passed on re-run.sharplsp/project/addCompileItemedits the.fsprojthrough the C# sidecar's MSBuild editing.EPERMand "watcher shutdown" errors. When the event is lost, the project is never reloaded.pull_diagnostics/monitor.rsgainswritten(paths). It posts the sameworkspace/didChangeWatchedFilesnotification the native watcher sends (type Changed,sharplspRescan: false) onto the foreground dispatch queue.project_edit.rscalls it after any compile-item edit that modified the project.pull_diagnostics/state.rsexposes the dispatch queue (inbound()). Both files stay under 500 lines.How Do The Automated Tests Prove It Works?
written_tests::a_project_file_the_host_writes_is_announced_as_a_watched_change(new) checks three cases:didChangeWatchedFilesarrives, carrying exactly[{ uri: <project>, type: 2 }]withsharplspRescan: false.--test-threads=1), and clippy is clean.workspaceleg runs the Add F# Source File suite end to end.