Fork me on GitHub
#conjure
<
2021-05-12
>
ambrosebs03:05:11

Just upgraded conjure, the inline evaluation is very nice thanks for adding it back @olical (though I never saw the original impl which IIRC broke recently)

pithyless07:05:58

jjkk:wq 馃憢

pithyless07:05:22

I've got a question for the conjure users - can you point me to any workflows or plugins on how you work with big/nested map datastructures? Looking for something where I can fold/unfold and jump around without being overwhelmed by just pprint'ing everything to a text-based repl output.

pithyless07:05:07

If this is enabled by default, feel free to just correct me. I'm currently an evil-mode doom-emacs (and reveal) user, but I'm wondering how well this works in other environments. I saw a video with calva with built-in folding/unfolding of these big nested data structures (which makes sense, considering the underlying browser); and I was a bit envious to be honest. 馃檪 Wondering if the vim users have also solved this problem.

Olical14:05:08

I don't personally use any extra tooling, I've found the digging tooling in spacemacs/cider actually really frustrating and confusing, personally. Like adding a UI that isn't actually just text into my text editor always feels wrong to me. Like suddenly keys that have done one thing forever now do something else. So my approach is to get-in things where required or just use % to hop between matching braces, no matter how deep I am in a structure that'll work. You can also use vim-sexp etc to alter the forms, even raising one form out to work on it. Sometimes I'll go deep into a structure in the log and eval a nested part which extracts it and pprints it at the bottom of the log. So my approach is regular nvim keys / tools + evaluating sub-parts or using code to extract things. My REPL is the way I explore data 馃槃 Maybe not a super useful answer, but just some context of how I approach things (large data structures are actually a rare thing for me to even look at!)

pithyless15:05:47

Thanks for the feedback! I'll often be working with large maps of data from outside sources and/or stuff that's not even printable (i.e. a nested map with a reference to some huge lazy-seq that would be a mistake to accidentally print when evaling); where I'd like tools to help me easily explore and poke around. I think part of the answer is the way you work with your REPL history (that I saw in one demo), where you treat it as another regular buffer and jump around and re-eval parts of the data to push it to the bottom of the log. But another part I believe may be pushing some of this work out of the text editor and into something that allows for different kinds of visualizations and interactions. Projects that come to mind are REBL, Reveal, and to some extent even things like Pathom Viz or Fulcro Inspect. I think what got me intrigued is that Calva running in essentially a browser can integrate some of those kinds of UI experiments possibly more seamlessly than outside tools. Nevertheless, the original post stemmed from an idea that if anyone knows how to deal with this kind of data archaeology without leaving the terminal, it would be the ViM folks. :)

pithyless15:05:22

As a counter-point, one example of a "low-tech" way of exploring these kinds of data-structures is using malli/provide to help infer what the schema is given some example data set. This way, you get an imperfect but high-level idea of how heterogeneous your input data set is and maybe some better idea of what's inside.