You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Lifecycle] Investigate missing formatter fallback during replacement #139
During an extension-driven restart with isFormatter: true, the old client's state listeners are disposed before the old client is stopped. If the old client was Running, the placeholder is not re-registered at the beginning of the restart. After the old client stops and while replacement startup is pending, no fallback placeholder is registered.
Reproduction
Start with a Running formatter client and its placeholder unregistered.
Trigger runServer() again, allowing the old stop to finish while holding the replacement client's start() pending.
Observe that the old client is Stopped and the placeholder remains unregistered until the replacement finishes.
Confirmed using the real createToolContext and restartServer orchestration with the existing stateful client mock on Node 24.17.0. The S3 characterization test also protects this existing boundary. The effect on the live VS Code formatter picker has not been verified in an extension host; a formatter could temporarily disappear while replacement startup is pending.
Follow-up
Decide whether a fallback should be available in this interval and, if so, how to restore it without reintroducing duplicate formatter entries while the old client is still healthy. Discovered while reviewing #137; that issue is intentionally tests-only.
Activity
test: characterize TypeScript client lifecycle boundaries (S3) (#140)
fix: restore formatter fallback during server replacement (microsoft#144