-
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
Would like support for a VM Service query for null-safety mode (mixed, sound) #43588
Comments
Flags that can be set in `Dart_IsolateFlags` are now surfaced via the Isolate JSON object returned from the service protocol. Currently only returns boolean flags. Related: #43588 Change-Id: I54a30155778de8612105eb4a5f60f8a222a086b4 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/165403 Commit-Queue: Ben Konyi <bkonyi@google.com> Reviewed-by: Ryan Macnak <rmacnak@google.com>
Both the |
I'm not seeing sound-null-safety set to true. I tried reading values from the flag list using hello_world. Step 1: update examples/hello_world
Step 2: print out flag value during flutter run
Step 3:
|
For the web we explicitly return an empty array. @jakemac53 and @annagrin is there a way to tell when the Frontend Server / build_web_compilers is run with null safety? We could even do an evaluation on the running app if necessary. Maybe @nshahan has some ideas. |
Edited to reflect the way this works now. I forgot we made some changes here to the bootstrapping. It seems like it would make more sense to retrieve the runtime mode elsewhere before the app starts running because we actually need to know That said the old standby test is |
Is this something we should / could add in the DDC metadata? |
I was talking with @annagrin about this topic earlier. She is investigating some refactoring of the infrastructure that needs to happen so the expression evaluation can use the correct mode. The case is a little different between frontend_server and build_web_compilers. In the build_web_compilers case DDC could probably deduce the mode based on the dart sdk .dill file that is provided when compiling modules. As long as everything is working correctly the sdk .dill mode should match the version of the dart_sdk.js that is used when running. We could emit the mode in every metadata file. I don't know exactly what happens in the frontend server setup or what emits the metadata file. Does this still hit the code path in DDC that writes the metadata file? |
That is my understanding. @annagrin would know best though. |
The flutter tool would like to perform analytics tracking of hot reload performance based on mixed vs sound. The tool can sort of guestimate sound-ness by checking command line flags and parsing the entrypoint language version, or by performing an expression evaluation - but since the VM should already know it would be great if this could be surfaced through the VM Service API. It would be great if dwds could also support this query, too (@grouma ). FYI @jacob314 might have needed this too.
@bkonyi
The text was updated successfully, but these errors were encountered: