-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Crash in dart migrate #43956
Comments
/cc @stereotype441 |
Marking this as a P2 - we can bump up in the future if we determine this is impacting more than a few users. |
Can we repo this consistently? |
@devoncarew how do we know it's just a few users? We have less than 100 users using the null safety experiment, so even with a single repro, that a 1% failure rate. |
We haven't seen this before, with non-trivial internal usage. @stereotype441 - do you mind looking at this, to determine if this is likely to be something user will hit (i.e., not a less likely coding construct)? |
I'm able to reproduce this using Quiver commit google/quiver-dart@6d9643f and the latest Dart SDK as of 332ce76. I'll investigate further to try to figure out the root cause, and when I do, I'll update this bug with information about how large I think the impact is. Side note: users who encounter this problem are not dead in the water. Following the tool's suggestion of re-running with |
Ok, I've tracked the bug down far enough to estimate its impact. I believe it's fairly common. The bug will occur with any call to @override
Match matchAsPrefix(String str, [int start = 0]) {
return allMatches(str)
.firstWhere((match) => match.start == start, orElse: () => null);
} I think this is sufficiently bad to consider a P1. Fortunately the fix should be fairly easy, and I have time available to work on it now. |
Fix is out for review: https://dart-review.googlesource.com/c/sdk/+/170162 |
Ran
dart migrate
in the root of package:quiver at 35f6d18fe989f92314210c20e3a2636cb90ba4ad.Dart SDK version: 2.11.0-260.0.dev (dev) (Mon Oct 26 03:52:00 2020 -0700) on "linux_x64"
Expected behaviour: runs migration and hands me a URL for the tool service.
Actual behaviour:
The text was updated successfully, but these errors were encountered: