Better HN
topnewbestaskshowjobs
Log inSign up

jpmonettas

58 karma · joined Nov 26, 2022 (3y ago) · 16 submissions

Submissions

comment 1y ago · link · parent

Clojure has tree-seq https://clojuredocs.org/clojure.core/tree-seq

comment 1y ago · link · parent

FlowStorm A FOSS time travel debugger for Clojure https://www.flow-storm.org/

comment 2y ago · link · parent

Cool! I love how this written and how powerful that whole approach feels for teaching/learning.

comment 2y ago · link · parent

Thanks! I started with cljfx and then moved to pure javafx, first because it wasn't straight forward for me to understand the performance overhead of cljfx under different scenarios (when using subscriptions and contexts), and second because I want to drag as few dependencies as possible so they don't conflict with debuggee one's.

comment 2y ago · link · parent

So recording in FlowStorm doesn't use Clojure metadata capabilities in any way, it is basically about storing function calls, function returns and the pointers to all expressions intermediate immutable values together with their code coordinates.

comment 2y ago · link · parent

Not sure I follow, can expand on that? I gave a presentation on it recently https://www.youtube.com/watch?v=BuSpMvVU7j4 which goes over demos and implementation details if you are interested in those topics.

comment 2y ago · link · parent

Cool! I wrote something on the same spirit but for Clojure, called FlowStorm http://www.flow-storm.org/

For instrumentation, instead of an instrumenting agent it uses a fork of the official Clojure compiler (in Clojure you can easily swap compilers at dev) that adds extra bytecode. What is interesting about recording Clojure programs execution is that most values are immutable, so you can snapshot them by just retaining the pointers.

Edit: Since the OP demo is about exploring a web app for people interested in this topics I'm leaving a demo of FlowStorm debugging a web app also https://www.youtube.com/watch?v=h8AFpZkAwPo

comment 2y ago · link · parent

Have you seen http://www.flow-storm.org/. It does time travel debugging for Clojure and has a bunch of features.

comment 2y ago · link · parent

I'm working on http://www.flow-storm.org/ A time travel debugger for Clojure with some unique features, aiming to enhance the already awesome interactive development of Clojure by enabling you to record and explore executions on demand.

10.

Debugging compilers in Clojure(jpmonettas.github.io ↗)

58 points · by jpmonettas · 3y ago · 12 comments

comment 3y ago · link · parent

Hi Kenny! Go ahead! There is a ton to explore in this area, so looking forward to whatever works for you.

ClojureDart is still on FlowStorm roadmap, just waiting for the self hosted version there.

comment 3y ago · link · parent

Author here. Thanks for the feedback! and yeah I agree adding those features to the landing page is a good idea. I'll add them.

Regarding tools that offer similar capabilities in other languages, I'm not aware, and I have my opinion on why this could be https://github.com/jpmonettas/flow-storm-debugger#arent-omni... but I could be wrong.

But there are time travel debuggers for other languages for sure, and some omniscient debuggers too, but with different capabilities.

13.

FlowStorm: Omniscient time travel debugging for Clojure(flow-storm.org ↗)

25 points · by jpmonettas · 3y ago · 5 comments

comment 3y ago · link · parent

This is another example, a tracing time travel debugger for Clojure https://github.com/jpmonettas/flow-storm-debugger

Supports a bunch of stuff described there and more.

comment 3y ago · link · parent

Nice, thanks for the links.

Yeah I don't know how stickers trace code, but FlowStorm tracing debugger takes advantage of the immutable data structures used everywhere and by default in Clojure. You can then instrument entire code bases, run them, and tracing is just a matter of retaining(leaking) pointers of every intermediate expression so the GC doesn't collect them. I don't think this is possible when working with mutable objects, since then only way would be to somehow serialize the objects involved at every step so you can analyze the data later, which is prohibitively expensive in most situations.

comment 3y ago · link · parent

Similar to SLIME, there is Cider (https://docs.cider.mx/cider/index.html) for Emacs.

There are a lot of debugging and data visualization tools for the repl with features I haven't found in Common Lisp like :

- https://github.com/jpmonettas/flow-storm-debugger (which I'm actively working on)

- https://github.com/djblue/portal