Skip to content

[dart2js] New converter to vm devtools format not working for CM Dart web app #49546

Open
@IslinaS

Description

@IslinaS

The current program that converts the dart2js --dump-info output into the format accepted by vm devtools work for hello_world.dart apps, as well as more complex dart web apps with deferred units. However, when run on the CM Dart web app, I encounter the following error:

Unhandled exception:
NoSuchMethodError: The method 'putIfAbsent' was called on null.
Receiver: null
Tried calling: putIfAbsent("", Closure: () => Map<String, dynamic>)
#0 Object.noSuchMethod (dart:core-patch/object_patch.dart:38:5)
#1 _addChild (package:vm_snapshot_analysis/treemap.dart:223:27)
#2 _addSymbol (package:vm_snapshot_analysis/treemap.dart:254:10)
#3 _treemapFromInfo.recurse (package:vm_snapshot_analysis/treemap.dart:142:7)
#4 _treemapFromInfo.recurse (package:vm_snapshot_analysis/treemap.dart:146:7)
#5 _treemapFromInfo (package:vm_snapshot_analysis/treemap.dart:152:5)
#6 treemapFromInfo (package:vm_snapshot_analysis/treemap.dart:106:3)
#7 DevtoolsFormatCommand.run (file:///Users/islinashan/dart-sdk/sdk/pkg/dart2js_info/bin/src/to_devtools_format.dart:41:36)

#8 CommandRunner.runCommand (package:args/command_runner.dart:209:13)

The program was suspended at the node named "ads.awapps2.shared.settings.ad_scheduling_type.ad_scheduling_type". The path to this node should be of depth 6, but the treemapFromInfo function is unable to dissect this path and interprets it of depth 1 instead. This error could be averted by changing the name of the library node to "<unnamed>", which is an exception handled by the to_devtools_format converter program, but this solution does not address the root cause of this issue.

Metadata

Metadata

Labels

area-web-jsIssues related to JavaScript support for Dart Web, including DDC, dart2js, and JS interop.dart2js-infoweb-dart2js

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions