Fork me on GitHub
#portal
<
2022-04-25
>
djblue02:04:02

I put together a https://github.com/djblue/portal/blob/master/doc/guides/test-runner.md for leveraging the new test report viewer.

🚀 3
thanks3 1
nate19:04:51

Replacing the default behavior for logs works beautifully!

❤️ 2
nate19:04:03

Thanks for adding this

nate19:04:58

Is there a way to configure the default inspector viewer to expand?

djblue19:04:06

At what level of depth?

nate19:04:15

I currently have this:

nate19:04:31

and would like to have the mulog/data expanded

nate19:04:44

I can expand it, but when a new row is added, the expansion is reset

nate19:04:10

I had some success with setting the viewer to pprint:

djblue19:04:30

There isn't an easy way to force something to be expanded currently, so using another viewer as the default would be easier

nate19:04:41

cool, that works for me right now

djblue19:04:43

The tree viewer might be another option

nate19:04:49

this is fantastic

🙏 1
seancorfield19:04:55

I have a hot key bound to a variant of tap> that adds metadata to ask for the tree viewer.

djblue20:04:48

Also, if these aren't being submitted via the REPL, doing something like:

(update log :mulog/data vary-meta assoc :portal.viewer/default :portal.viewer/tree)
might work :thinking_face:

steveb8n23:04:28

Is there a video somewhere of this workflow? It would help me understand the effort and ROI

djblue23:04:47

@U0510KXTU a video of what part exactly?

steveb8n10:04:04

Setup to see how/effort required to setup. Then the improvement from seeing logs and test reports in portal vs ide console

djblue16:04:38

It depends on what you use for logging, but here is a guide for https://github.com/djblue/portal/tree/master/examples/timbre. It's particularly nice for the logs in my app since they have a ton of context which does not print well at a terminal 👌

seancorfield17:04:41

I patch tools.logging when I start my REPL to send data to Portal -- works really well for me: https://github.com/seancorfield/dot-clojure/blob/develop/dev.clj#L83

🚀 1
steveb8n05:05:00

loving this timbre workflow. thank you! next step: getting test outputs into portal as well

steveb8n05:05:10

re the suggestion of a video: even though the instructions are simple and easy, a short video would showing how nice it is would have hooked me earlier. just a thought @U1G869VNV

1