cider

2024-08-21T08:50:55.431309Z

Why does CIDER ask if I want to re-use buffers for dead REPLs? I've been answering "yes", but I'm not sure why. Could CIDER have an opinion on the matter for me?

➕ 2
oyakushev 2024-08-21T09:08:12.402879Z

Interested in this as well. Most of the time it feels like a decision I don't make consciously, and it doesn't matter that much.

mkvlr 2024-08-21T09:17:46.333769Z

yep, I’d also prefer if the default was yes here

❤️ 1
Mateusz Mazurczak 2024-08-21T11:34:53.017209Z

I always say no, cause I want it clean lol

2024-08-21T12:27:59.062189Z

Yes, exactly why I am asking: I don't even know what the ramifications are. Hence my initial (non-rethorical) question. Why does it ask me?

yuhan 2024-08-21T12:35:19.347949Z

there's a defcustom for this - cider-reuse-dead-repls

🙏 7
🙏🏻 1
mkvlr 2024-08-21T12:36:07.507439Z

I’d also be fine with defaulting to not re-use a buffer (though I personally prefer reusing it as I can still clear it and I’ve never had the need to look up things from a dead repl buffer) but find being asked as a default often an unhelpful interruption.

yuhan 2024-08-21T12:41:45.060419Z

Yeah, my preferred setting is auto , but I decided to keep the preexisting behaviour as default when introducing it in https://github.com/clojure-emacs/cider/pull/3354

yuhan 2024-08-21T12:43:18.094769Z

If this is a popular opinion feel free to open an issue for changing the default :)

bozhidar 2024-08-21T20:02:21.524479Z

I'd be fine with changing the default. Originally the assumption was that people won't encounter this very often, so it was fine to prompt them when this happened.

bozhidar 2024-08-21T20:02:44.110389Z

I rarely restart connections, so this almost never happens to me. 😄

yuhan 2024-08-22T00:52:29.026029Z

Yeah, I'd go long periods without encountering it too, but once you're dealing with a bug that crashes the JVM (breaking the connection with Cider 'unexpectedly') and having to restart the REPL every couple of minutes, then it becomes an annoyance having to answer the prompts on every reconnect and/or manually clean up all those 'dead REPL' buffers.

👍 1
2024-08-22T03:19:18.233209Z

Just so, yuhan. My suggestion would be to change the default to auto.

licht1stein 2024-09-07T08:21:38.600879Z

I get this prompt a lot 😂 Use case: connect to a local repl, do stuff. Disconnect and connect to a remote repl, then disconnect and reconnect to local.