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
VM Service WebSocket disconnects after idle period on Windows 11 with Norton 360, causing errno 232 pipe crash #6026
VM Service WebSocket connection (ws://127.0.0.1:.../ws) disconnects after a period of inactivity (between 4-20 minutes, variable), causing a pipe crash when hot reload is attempted. This affects both Chrome and Android targets.
The DTD WebSocket ping fix from PR #5828 (v3.124) does not cover the VM Service WebSocket. A similar keepalive ping is needed for the VM Service connection.
Stack trace:
ResidentRunner._serviceDisconnected (resident_runner.dart:1405)
WindowsStdoutLogger.writeToStdOut (logger.dart:737)
FileSystemException: writeFrom failed (OS Error: The pipe is being closed, errno = 232)
Log evidence:
21:12:12 | supabase init completed
21:16:34 | Performing hot reload...
21:16:35 | getVM: (-32000) Service connection disposed
4 minutes 22 seconds of inactivity → VM Service disconnected.
Environment:
Flutter 3.41.4, Dart 3.11.1
Dart-Code extension v3.132
Windows 11 25H2 (10.0.26200.8117)
Norton 360 installed (even with all protection disabled, issue persists)
Reproducible on: Chrome web, Android device
Dart-Code extension v3.132 (also tested with pre-release versions of both Dart and Flutter extensions)
Flutter stable channel and dev channel (3.13.0-5.0.dev) — both affected
Target: Windows desktop, but the issue is target-independent (reproduces on Android and Chrome as well)
The disconnection happens after a period of inactivity regardless of the target platform, but it also occurs during normal development with eventual hot reloads — sometimes as soon as 1–3 minutes into a session, even with a fresh empty project.
Disabling Norton does not resolve the issue — only fully uninstalling it does.
This has been quite frustrating to work around and is significantly impacting the development experience. Happy to provide any additional logs or information if helpful.
@NicoHype same question as above - are you able to provide exact steps that reproduce this for you? For example exactly how you're launching the app, and exactly where you're seeing the error messages (a screenshot might help).
@NicoHype thanks - the "Lost connection to device" error looks like the flutter tool losing the connection to the device rather than VS Code/the debugger losing connection to the VM/DTD/etc. (which was the original issue).
@bkonyi what kind of connections does the flutter tool hold open to the device? Am I right in thinking it also holds a VM Service connection open over a WebSocket too? If so, I wonder whether that also needs a pingInterval setting (similar to we did for DAP)?
@bkonyi what kind of connections does the flutter tool hold open to the device? Am I right in thinking it also holds a VM Service connection open over a WebSocket too? If so, I wonder whether that also needs a pingInterval setting (similar to we did for DAP)?
Yup, it does keep a VM service connection active, so we probably do need a ping interval setting as well.
@bkonyi thanks! Would package:vm_service be a better place to do this, so all clients get it?
I'm not sure we can do it from the server because of flutter/dart-intellij-third-party#208, but I think doing it from the client should be fine, because we know that the Dart client itself handles it (both sides of the connection are Dart, no external users).
Yeah, that would make sense. Is there any situation where we wouldn't want a ping interval, or do you think this is something safe to enable all the time?
Yeah, that would make sense. Is there any situation where we wouldn't want a ping interval, or do you think this is something safe to enable all the time?
I don't think so. It could make the connection drop a bit more eagerly (eg. if nothing is using the connection but it dropped, previously we just wouldn't know until we tried to use it, whereas with pingInterval it would close as soon as a ping fails to respond). I'm not sure that's a bad thing though.
We enable it always for outbound connections from Dart-Code/DAP now. We had to revert it on the server-side from DTD due to the IntelliJ plugin WebSocket library not implementing it (despite it being part of the standard), but I think once that's fixed we should re-enable it there too (to cover any other clients connecting to it on machines with Norton/etc.).
If anyone is able to test on latest Flutter master, the VM Service connection should now have the same pingInterval to keep it alive that we added elsewhere.
I expect this will resolve the problem, but if it does not, please let me know and we can re-open this and dig further.
@NicoHype thanks for testing, and I'm sorry to hear it didn't resolve the problem.
Is it possible you could try running from the terminal (flutter run) and leaving that to see whether the issue reproduces there? It might help eliminate some parts (like VS Code and the debug adapter) to help narrow down what's being dropped.
cc @bkonyi in case he has any other ideas about what connections might be open besides the one we just updated.
@NicoHype thanks for testing, and I'm sorry to hear it didn't resolve the problem.
Is it possible you could try running from the terminal (flutter run) and leaving that to see whether the issue reproduces there? It might help eliminate some parts (like VS Code and the debug adapter) to help narrow down what's being dropped.
cc @bkonyi in case he has any other ideas about what connections might be open besides the one we just updated.
Using flutter run, the behavior is the same, unfortunately.
@NicoHype thanks, that's useful info. Do you want to file an issue at https://github.com/flutter/flutter/ (and link back to this issue for context), since it makes sense to track instead of here (since it's not something fixable here in the VS Code extension).
I wonder if there's any way to get Norton to log the connections that it's proxying (and terminating!) that might help narrow this down.
It might also be useful to know how long between the app launching and the disconnection (I think originally we saw issues at 30s or 60s, but the first message in this thread suggests 4-20 minutes which is quite different).
Activity
DanTup commentedon Apr 6, 2026
@gabriel9004 can you provide steps to reproduce this?
We set
pingIntervalin the base debug adapter when connecting to the VM Service here:https://github.com/dart-lang/sdk/blob/da2dc44dda58c24dfd3664117579f7d0aaa8cfaa/pkg/dds/lib/src/dap/adapters/dart.dart#L2835
I would expect that to handle the issue you describe.
NicoHype commentedon Apr 9, 2026
I can confirm this issue on my end as well.
Environment:
The disconnection happens after a period of inactivity regardless of the target platform, but it also occurs during normal development with eventual hot reloads — sometimes as soon as 1–3 minutes into a session, even with a fresh empty project.
Disabling Norton does not resolve the issue — only fully uninstalling it does.
This has been quite frustrating to work around and is significantly impacting the development experience. Happy to provide any additional logs or information if helpful.
Thanks!
DanTup commentedon Apr 9, 2026
@NicoHype same question as above - are you able to provide exact steps that reproduce this for you? For example exactly how you're launching the app, and exactly where you're seeing the error messages (a screenshot might help).
Thanks!
NicoHype commentedon Apr 10, 2026
@DanTup Using the F5 shortcut in VS Code, the debug session exits after about 3-5 minutes even with periodic hot reloads every 10–30 seconds:
second error type:
DanTup commentedon Apr 10, 2026
@NicoHype thanks - the "Lost connection to device" error looks like the
fluttertool losing the connection to the device rather than VS Code/the debugger losing connection to the VM/DTD/etc. (which was the original issue).@bkonyi what kind of connections does the
fluttertool hold open to the device? Am I right in thinking it also holds a VM Service connection open over a WebSocket too? If so, I wonder whether that also needs apingIntervalsetting (similar to we did for DAP)?bkonyi commentedon Apr 10, 2026
Yup, it does keep a VM service connection active, so we probably do need a ping interval setting as well.
DanTup commentedon Apr 14, 2026
@bkonyi thanks! Would
package:vm_servicebe a better place to do this, so all clients get it?I'm not sure we can do it from the server because of flutter/dart-intellij-third-party#208, but I think doing it from the client should be fine, because we know that the Dart client itself handles it (both sides of the connection are Dart, no external users).
bkonyi commentedon Apr 14, 2026
Yeah, that would make sense. Is there any situation where we wouldn't want a ping interval, or do you think this is something safe to enable all the time?
DanTup commentedon Apr 14, 2026
I don't think so. It could make the connection drop a bit more eagerly (eg. if nothing is using the connection but it dropped, previously we just wouldn't know until we tried to use it, whereas with
pingIntervalit would close as soon as a ping fails to respond). I'm not sure that's a bad thing though.We enable it always for outbound connections from Dart-Code/DAP now. We had to revert it on the server-side from DTD due to the IntelliJ plugin WebSocket library not implementing it (despite it being part of the standard), but I think once that's fixed we should re-enable it there too (to cover any other clients connecting to it on machines with Norton/etc.).
[vm_service] Allow setting a pingInterval on VM Service connections a…
gabriel9004 commentedon Apr 17, 2026
Sorry for the late reply! I uninstalled Norton completely and confirmed that was the problem. I'm not getting the error anymore.
DanTup commentedon Apr 23, 2026
If anyone is able to test on latest Flutter master, the VM Service connection should now have the same
pingIntervalto keep it alive that we added elsewhere.I expect this will resolve the problem, but if it does not, please let me know and we can re-open this and dig further.
NicoHype commentedon May 5, 2026
I tested on the latest Flutter master, and the issue still persists.
I'm using Dart/Flutter VS Code extensions
v3.134.0DanTup commentedon May 5, 2026
@NicoHype thanks for testing, and I'm sorry to hear it didn't resolve the problem.
Is it possible you could try running from the terminal (
flutter run) and leaving that to see whether the issue reproduces there? It might help eliminate some parts (like VS Code and the debug adapter) to help narrow down what's being dropped.cc @bkonyi in case he has any other ideas about what connections might be open besides the one we just updated.
NicoHype commentedon May 5, 2026
Using
flutter run, the behavior is the same, unfortunately.DanTup commentedon May 5, 2026
@NicoHype thanks, that's useful info. Do you want to file an issue at https://github.com/flutter/flutter/ (and link back to this issue for context), since it makes sense to track instead of here (since it's not something fixable here in the VS Code extension).
I wonder if there's any way to get Norton to log the connections that it's proxying (and terminating!) that might help narrow this down.
It might also be useful to know how long between the app launching and the disconnection (I think originally we saw issues at 30s or 60s, but the first message in this thread suggests 4-20 minutes which is quite different).
Thanks!