Fixes an issue where, when Dart DevTools reconnects to a web app, it is no longer aware of any of the registered service extensions.
Why was this happening?
In DWDS, all service extensions (including hot-restart) are registered on a client that is directly connected to the VmService, instead of connected to DDS
When a user re-connects to a web app from DevTools, DevTools calls streamListen on the Service stream
DDS intercepts the streamListen request (so it never gets to DWDS) and sends back all of the service extensions it is aware of
However, because DWDS registers the service extensions on a client that is directly connected to the VMService, DDS is unaware of the service extensions and therefore can’t send them back.
What is the fix?
DWDS needs to connect to DDS instead of directly to the VMService so that DDS will be aware of the service extensions that DWDS has registered.
Fixes https://github.com/flutter/devtools/issues/7313
Fixes an issue where, when Dart DevTools reconnects to a web app, it is no longer aware of any of the registered service extensions.
Why was this happening?
What is the fix?
yieldControlToDDS
needs to be part of the VM service interface instead of registered by DWDS: https://dart-review.googlesource.com/c/sdk/+/357720flutter._listViews
service extension still needs to be registered directly with the VM (instead of via DDS) until https://github.com/dart-lang/webdev/issues/1315 is fixed.