You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
sigurdm opened this issue
May 15, 2020
· 4 comments
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.P4type-bugIncorrect behavior (everything from a crash to more subtle misbehavior)
My motivation is that I would like to url-encode the sdk-version into the name of a snapshot(for pub run) to avoid running a bad snapshot.
I feel strongly that we should not be trying to hack around a bug in the SDK, pub is not the only place we use this pattern and we should not go rewrite them all to encode the SDK version in a file name. Have we filed an issue for not getting the correct exception on a bad snapshot?
srawlins
added
area-vm
Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.
type-bug
Incorrect behavior (everything from a crash to more subtle misbehavior)
labels
May 15, 2020
My motivation is that I would like to url-encode the sdk-version into the name of a snapshot(for pub run) to avoid running a bad snapshot.
I feel strongly that we should not be trying to hack around a bug in the SDK, pub is not the only place we use this pattern and we should not go rewrite them all to encode the SDK version in a file name. Have we filed an issue for not getting the correct exception on a bad snapshot?
We should not work around a bug - true. But I find that encoding the sdk version in the filename actually it is nicer for pub run for the following reasons:
We are moving to using a subprocess instead of an isolate for pub run (Use subprocess for "pub run" and allow vm options pub#2492). Meaning that there is no exception to catch, we would have to interpret stdout and exitcode, which we can never ensure are not overlapping with what the program itself would return. Alternatively the VM would have a mode that only detected validity of the snapshot. But then that would require one more subprocess call before starting the program.
We can have one snapshot per installed SDK without conflict - maybe not a common use-case, but when you are testing a program with different sdks it works nicely.
For other use-cases we do want the VM to throw a known exception on Isolate.spawnUri, and it would also be nice to have a way to test a snapshot's validity before running it.
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.P4type-bugIncorrect behavior (everything from a crash to more subtle misbehavior)
To reproduce reate
bin/ab%22.dart
with a small program, and rundart bin/ab%22.dart
prints:
The same happens for snapshots.
My motivation is that I would like to url-encode the sdk-version into the name of a snapshot(for pub run) to avoid running a bad snapshot.
The text was updated successfully, but these errors were encountered: