Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Breakpoints in Dartium not working

So if I add break points in .dart files that are located in /web directory of my project, it works fine. For example I'm using AngularDart and the main.dart file works. However when I try to put a breakpoint in anything in the /lib directory, Dartium doesn't stop on them.

How can I get the breakpoints in Dartium to work with the /lib directory?

Note that I've tried putting breakpoints with Dart Editor, IntelliJ with Dart Plugin and also directly in Dartium and nothing works. Is this intended?

like image 348
Pacane Avatar asked Dec 09 '25 07:12

Pacane


2 Answers

To set breakpoints in dependencies search the source inside the (no domain) node and set the breakpoint there. Breakpoints don't hit when set somewhere in the packages node.

enter image description here

You can also use the breakpoint statement for the debugger top pop up. See Does Dart have a 'breakpoint' statement? for more details.

like image 104
Günter Zöchbauer Avatar answered Dec 11 '25 21:12

Günter Zöchbauer


I will combine the accepted answer + comment to that answer. Breakpoints 100% works only when you set them for files inside (no domain) category on Sources tab.

As I understand, in category with your domain name they are working only for files that was included with <script> tag. They won't work for imported files.

I have created an issue: Dartium ignores breakpoints set not in (no domain) category.

like image 34
Paul Annekov Avatar answered Dec 11 '25 21:12

Paul Annekov



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!