-
Notifications
You must be signed in to change notification settings - Fork 29.8k
Reland isolate platform channels with conditional compilation #111712
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
Reland isolate platform channels with conditional compilation #111712
Conversation
1372248 to
1af8300
Compare
1af8300 to
9aef5cc
Compare
This comment was marked as off-topic.
This comment was marked as off-topic.
| // found in the LICENSE file. | ||
|
|
||
| import 'dart:async' show Completer; | ||
| import 'dart:isolate' show ReceivePort; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the important line, now isolate is only brought in through a conditional import.
|
|
||
| import 'dart:async'; | ||
| import 'dart:developer'; | ||
| import 'dart:isolate' show ReceivePort; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: the removed import.
| /// [RootIsolateToken] as its argument. The value `null` is returned when | ||
| /// executed from background isolates. | ||
| ui.RootIsolateToken? get rootIsolateToken => ui.RootIsolateToken.instance; | ||
| static ui.RootIsolateToken? get rootIsolateToken => ui.RootIsolateToken.instance; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I switched this to static since it doesn't make sense to have a ServiceBinding.instance to call it because we want to call it from background isolates where there will be no ServiceBinding.
|
auto label is removed for flutter/flutter, pr: 111712, due to - The status or check suite Windows framework_tests_misc has failed. Please fix the issues identified (or deflake) before re-applying this label. |
Relands #111702 with conditional compilation to remove
dart:isolatefrom the web target.issue: #13937
WARNING: the added integration test doesn't run in presubmit.
Pre-launch Checklist
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.