Skip to content

Adding a condition to evaluations before logging? #566

Answered by Olical
Aleks-Petkov asked this question in Q&A
Discussion options

You must be logged in to vote

So the Clojure client has this because the REPL protocol does the trimming for us, I have a feeling a couple of other REPLs do too but not all of them, so this is quite a common problem.

Right now I think all you can do is wrap your calls in a call to some function like take which will only return the first n items from a given list, that way you can cap your output on expressions that you know will return a lot of items.

The was we could "fix" this in the Python client specifically would be to wrap every evaluation you perform in more code that will check the result type and try to trim it down if it's too big, but then we also need a way to say "ignore that rule, just give me everything…

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@Aleks-Petkov
Comment options

Answer selected by Aleks-Petkov
Comment options

You must be logged in to vote
1 reply
@russtoku
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants