Debugging the debugger.

I've spent some time recently trying to get Konqueror's JavaScript debugger in a shippable form for 4.0. The debugger was changed heavily from the 3.x version in a SoC project, making ground for much nicer UI. Unfortunately, it also barely worked.

I've fixed up a chunk of the issues, but there is still a long way to go in fixing up some remaining holes, and doing testing to improve stability. But, it's at least good enough for a screenshot:
... as well as some simple debugging tasks. Anyway, I am sort of curious: what do readers want from such a debugger? Now, I probably can't incorporate any non-minor suggestions in 4.0 (feature/string freeze), but it'd be good to know what direction to take, and some minor stuff is certainly tweakable.


wow, this looks great!

Currently I use FireBug a lot, some nice features are:
- dockable in the browser (you can step the script and see the output above)
- show variable content in tooltip
- flash dom-node in browser if mouse is moved over a dom-node in a watchpoint or console-output
- option to Break on all errors

All other very useful Firebug-features are out of the scope of a JS-Debugger.


By nikotto at Thu, 12/20/2007 - 07:05

Firebug is impressive; it's the reason I switch back to firefox when doing any JS development. So feel free to steal features from them :)

The way backtraces are shown is also quite nice. You get a "semi-expanded" view of the arguments, and pretty much anything is clickable to get to its definition.

Alas, as nikotto said the rest is out of scope for a JS debugger / for 4.0.

By moltonel at Thu, 12/20/2007 - 10:28

Thanks for the suggestions. Sounds useful, though definitely 4.1 stuff... It doesn't really work all that well yet, some things are very tricky to get right :(

Regarding showing of variable contents in tooltips --- how does it work with different scopes, contexts. etc?

And, well.. It also seems like firebug gets it right in that debugging web stuff is an integrated experience.

By Maksim Orlovich at Fri, 12/21/2007 - 22:41

awesome. :)

it's been ages since I quit the evil job where I had to do javascript, so I don't need this myself... but I'm still really happy to see it :)

By chani at Thu, 12/20/2007 - 16:45

I don't now why but my comment has been "flagged as spam" and as such did not appear here. So I repost it with all the nice
links and references removed. What about setting up a captcha instead?

It would be nice if Konqueror would support logging to the Javascript Console as Safari does using
windows.console.log("your text here")

It would be even nicer if it could support all logging features that Firebug sports:

console.log(object[, object, ...])
console.debug(object[, object, ...])[, object, ...])
console.warn(object[, object, ...])
console.error(object[, object, ...])

This logging facility is increasingly widespread, even Internet Explorer supports it if you install
IE WebDeveloper V2.

By kabsi at Tue, 02/12/2008 - 09:50