Skip to content

"No frames available" error when debugger is paused inside async javascript code. #5287

@annagrin

Description

@annagrin

Repro steps:

Flutter's example/hello_world directory:

  • run flutter run -d chrome
  • open the Dart DevTools uri
  • hit pause and run until you DevTools does not show where it stopped (takes about 5-6 attempts for me)
  • evaluate "true" in the evaluation box
  • observe "No frames available" error

image

Chrome does show a list of frames available, but all of them async and pretty sure they are all from js code:

image

Some background

In this example I paused the app, and hit javascript code with no frames on the stack related to dart.

@elliette looks like the error comes from DevTools, and it happens before the call to chromeProxyService.evaluateInFrame.

Potential solutions:

  • Make dwds continue executing until dart code is hit. Not sure what happens if it never does - in that case the pause will appear not working, so maybe we need a timeout with a warning? This change, if we prefer it, would be most easily done in dwds: Pause in dart code instead of JS when user hits pause? dart-lang/webdev#1999

  • Or simply assume we only have javascript frames in that case and report an error from DevTools describing that evaluating inside javascript code is not currently supported.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions