Closed
Description
Environment
- Dart 3.5.2
- Flutter 3.24.2
- macOS 14.4.1
Description
When building a project for web with wasm, the generated source map file has an empty "names" field. This won't allow mapping symbol names to stack frames, which hinders debugging capabilities.
I have checked this commit: 10742d9
which asserts the function name in the source_map_simple_test.dart so it should work (or at least used to work)
Maybe I'm also missing some setup detail.
Steps to Reproduce
Example 1: Flutter
- Create a new Flutter web project for example through Android Studio
- Run the command
flutter build --wasm --source-maps
- Examine the generated
main.dart.wasm.map
file
Example 2: Dart
- Create a Dart Web project with
dart create -t web mywebapp
- Compile WASM:
dart compile wasm web/main.dart
- Examine the generated
main.wasm.map
file
Expected Behaviour
The "names" field in the main.dart.wasm.map
file should contain symbol names that can be used to map to stack frames.
Actual Behaviour
The "names" field in the main.dart.wasm.map
file is empty.
Example Sourcemap Snippet
{
"version": 3,
"sources": [
"... etc",
"org-dartlang-sdk:///lib/_internal/wasm/lib/date_patch_patch.dart"
],
"names": [],
"mappings": [
"... etc",
"0r8BAuM+C,IAAd,EAAK,C,yBA4BvB,CACI,WAAF,CAAoB,WAAH,CAqE9B"
]
}