Skip to content

Compile item edits reload the owning compiler directly, not via the file watcher (Windows F# add-file hover) - #613

Merged
MelbourneDeveloper merged 2 commits into
mainfrom
fix/project-edit-reloads-compilers
Nov 19, 2026
Merged

MelbourneDeveloper merged 2 commits into
mainfrom
fix/project-edit-reloads-compilers

Conversation

@MelbourneDeveloper

Copy link
Copy Markdown
Collaborator

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 .fsproj write; on Windows it sometimes didn't, and the new file stayed unowned, with no hover or diagnostics.

Details

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:
    1. Before the dispatch queue exists, the call is a no-op.
    2. Once the queue exists, one didChangeWatchedFiles arrives, carrying exactly [{ uri: <project>, type: 2 }] with sharplspRescan: false.
    3. Writing no paths sends no notification.
  • All 371 host unit tests pass (--test-threads=1), and clippy is clean.
  • On this PR, the Windows workspace leg runs the Add F# Source File suite end to end.

…e, so the F# compiler reloads and owns the new file even when the platform watcher misses the host's own write
@MelbourneDeveloper
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.
@MelbourneDeveloper
MelbourneDeveloper merged commit db4cb43 into main Nov 19, 2026
63 checks passed
@MelbourneDeveloper
MelbourneDeveloper deleted the fix/project-edit-reloads-compilers branch November 19, 2026 22:50
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