-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Unhandled exceptions in isolates does not terminate the VM #12587
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
Comments
I don't think this is the expected behaviour any longer: // Dart test program for testing that exceptions in other isolates bring down We specifically added code that will be notified if a spawned isolate had an unhandled exception. cc @floitschG. |
With the isolate refactoring the error should be propagated back to the spawner. But somehow this is not working. |
Any updates on this? Looking at tests/isolate/isolate2_negative_test.dart: @floitsch/iposva: Could you take a look? |
This seems to be related to issue #8. Assigning to VM for further investigation. (Ping me, if we misuse the API and should be able to handle these errors in Dart code). === Removed Area-Library label. |
Should an uncaught error in the original isolate terminate the program? |
This looks stale. The tests named above don't appear to exist anymore. |
This is still an issue. See for example: import 'dart:isolate';
import 'dart:async';
foo(x) {
print("throwing");
throw "in other isolate";
}
main() {
Isolate.spawn(foo, null);
new Timer.periodic(const Duration(seconds: 1), (_) { print("tick"); });
} Silently ignoring is the worst of all options. We should come up with a better way to deal with it. |
@floitschG Could you give this issue a better title? As stated, I think the VM is working as intended. Thanks. |
Fair enough. I will close this one. |
The tests
isolate/isolate2_negative_test.dart
isolate/isolate3_negative_test.dart
expect the VM to terminate when there is an unhandled exception in an isolate.
Might be releatd to issue #3734.
The text was updated successfully, but these errors were encountered: