• Ben Konyi's avatar
    Reland "Fix issue where DevTools would not be immediately available when using... · 5ea2be69
    Ben Konyi authored
    Reland "Fix issue where DevTools would not be immediately available when using --start-paused (#126698)" (#129368)
    
    **Original Description:**
    
    > Service extensions are unable to handle requests when the isolate they
    were registered on is paused. The DevTools launcher logic was waiting
    for some service extension invocations to complete before advertising
    the already active DevTools instance, but when --start-paused was
    provided these requests would never complete, preventing users from
    using DevTools to resume the paused isolate.
    > 
    > Fixes https://github.com/flutter/flutter/issues/126691
    
    **Additional changes in this PR:**
    
    The failures listed in https://github.com/flutter/flutter/pull/128117
    appear to be related to a shutdown race. It's possible for the test to
    complete while the tool is in the process of starting and advertising
    DevTools, so we need to perform a check of `_shutdown` in
    `FlutterResidentDevtoolsHandler` before advertising DevTools.
    
    Before the original fix, this check was being performed immediately
    after invoking the service extensions, which creates an asynchronous gap
    in execution. With #126698, the callsite of the service extensions was
    moved and the `_shutdown` check wasn't, allowing for the tool to attempt
    to advertise DevTools after the DevTools server had been cleaned up.
    
    ---------
    Co-authored-by: 's avatarZachary Anderson <zanderso@users.noreply.github.com>
    5ea2be69
Name
Last commit
Last update
.github Loading commit data...
.vscode Loading commit data...
bin Loading commit data...
dev Loading commit data...
examples Loading commit data...
packages Loading commit data...
.ci.yaml Loading commit data...
.cirrus.yml Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CODEOWNERS Loading commit data...
CODE_OF_CONDUCT.md Loading commit data...
CONTRIBUTING.md Loading commit data...
LICENSE Loading commit data...
PATENT_GRANT Loading commit data...
README.md Loading commit data...
TESTOWNERS Loading commit data...
analysis_options.yaml Loading commit data...
dartdoc_options.yaml Loading commit data...
flutter_console.bat Loading commit data...