Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Close the IntegrationTestTestDevice stream when the VM service shuts down #90022

Merged
merged 1 commit into from Sep 18, 2021

Conversation

jason-simmons
Copy link
Member

Fixes #89829

@flutter-dashboard flutter-dashboard bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Sep 14, 2021
@google-cla google-cla bot added the cla: yes label Sep 14, 2021
Copy link
Member

@jiahaog jiahaog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, LGTM!

Comment on lines +104 to +106
unawaited(vmService.service.onDone.whenComplete(
() => controller.local.sink.close(),
));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Can this be merged into the remoteMessages.listen above?

remoteMessages.listen(
  (String s) => controller.local.sink.add(s),
  onError: (Object error, StackTrace stack) => controller.local.sink.addError(error, stack),
  onDone: () => controller.local.sink.close(),
);

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The remoteMessages stream is not closed when the on-device process crashes.

That event appears to be signaled only by the VM service's onDone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tool Affects the "flutter" command-line tool. See also t: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[integration_test]: Tests never complete after native crash
3 participants