Skip to content

Clicking pause button can crash DevTools #5231

Description

@elliette

Ran into this debugging an internal app. Because we are null-asserting mainIsolate when checking whether the app is paused, if the mainIsolate is null DevTools will crash:

serviceManager.isolateManager.mainIsolateState!.isPaused,

Stack trace from Chrome DevTools:

main.dart.js:12053 Uncaught 
main.dart.js:75177 NoSuchMethodError: method not found: '_isPaused' on null
log @ main.dart.js:75177
main.dart.js:74215 NoSuchMethodError: method not found: '_isPaused' on null
main.dart.js:74215     at _DebuggingControlsState.didChangeDependencies$0 (https://b2607f8b04800100000144d90c0a823628fa9000000000000000001.proxy.googlers.com/main.dart.js:119632:168)
main.dart.js:74215     at StatefulElement._firstBuild$0 (https://b2607f8b04800100000144d90c0a823628fa9000000000000000001.proxy.googlers.com/main.dart.js:252207:30)
main.dart.js:74215     at StatefulElement.mount$2 (https://b2607f8b04800100000144d90c0a823628fa9000000000000000001.proxy.googlers.com/main.dart.js:252139:12)
main.dart.js:74215     at MultiChildRenderObjectElement.inflateWidget$2 (https://b2607f8b04800100000144d90c0a823628fa9000000000000000001.proxy.googlers.com/main.dart.js:251885:19)

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2important to work on, but not at the top of the work list.screen: debuggerIssues with the Debugger screen

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions