Fork me on GitHub
#cider
<
2020-07-01
>
jacklombard06:07:35

What is the use of the cider-nrepl middleware? Do I really need it to connect to an nrepl server using cider?

jacklombard06:07:53

What will I miss if I don’t use the middleware, I am able to connect fine to an nrepl server without the middleware

jacklombard06:07:50

I have inherited a project where there is hard dependency on cider-nrepl. We are not trying to aot compile our project for distribution so that the source is unavailable. I not be including project.clj in my jar file but cider-nrepl needs the project.clj and hence stops the jar from running because of this.

bozhidar07:07:25

@frozenfire1992 CIDER will work even without cider-nrepl, but it will be limited when it comes to functionality.

jacklombard09:07:21

Thank you! 🙂

bozhidar07:07:40

I think that making a hard dep to some project is kind of weird, as I doubt anyone would be running any of the advanced debugging features in production, but who knows.

jumar08:07:32

Can I somehow "open" the repl buffer literally? SImilar to what emacs/spacemacs offer me by default when opening a large file? The thing is that Emacs gets really slow when my app logs lot of messages to standard out so I'd like speed it up

bozhidar09:07:56

@jumar I guess you can just enable saving the REPL log to a file and open that file.

jumar09:07:59

You mean configuring my logging framework?

jumar09:07:20

It's rather special, but in this case I was also debugging an issue when the error happened only when writing to stdout

bozhidar09:07:13

I guess then you can save your REPL buffer as a file and work with that file directly.

jumar13:07:01

My problem is that Emacs/Cider is just really slow in this case - in terminal it’s fine but Emacs will freeze for up to a minute while waiting for the output to be written to the repl buffer; the process that generates this output only takes several seconds

bozhidar06:07:42

Emacs has well known issues with handling of long lines. That’s nothing that can be fixed in CIDER and the best recipe is to keep the REPL buffer’s size in check. https://docs.cider.mx/cider/repl/configuration.html#auto-trimming-the-repl-buffer

jumar07:07:15

Thanks - I'll try that; it could help

magra20:07:31

I know it might not help in your case. I disable logging to console, enable logging to a file and have a separate terimal window open with tail -f log.

jumar05:07:54

@U15BH4U4V that could work in most of the cases; I'll give it a try