Fork me on GitHub
#cider
<
2020-09-26
>
Gleb Posobin18:09:27

Cider or sesman slows down emacs when typing: there are noticeable delays after some of the keystrokes. Seems to happen when I have one cider session open, but the current clojure buffer belongs to a different project without a session started. Here is the profile, seems like cider tries to determine the current session on every key press, which calls file-truename recursively a lot: https://gist.github.com/posobin/41f01d386e516bcc13431c8281fb10cb Should I file this as a bug? If so, to cider or sesman?

practicalli-johnny20:09:02

If using something like parinfer and Cider with aggressive indent I could see this situation arising as they continually fight against each other as you’re typing.

Gleb Posobin21:09:25

Parinfer is off.

practicalli-johnny23:09:29

Sorry I don't have any other ideas, I've never seen that kind of issue in the last five years (using Cider & Spacemacs). Maybe someone else has suggestions.

bozhidar06:09:08

aggressive-indent-mode doesn't play nice with CIDER. If you disable it your problems will go away.

bozhidar07:09:50

You can still file a bug with sesman, as there might be some opportunity to improve the session resolution but for me with big enough files aggressive-indent-mode was slow even for Emacs Lisp and Clojure files without CIDER, that's why I stopped using it a long time ago.

Gleb Posobin13:09:11

@U051BLM8F Do you call the command to reindent the file manually then?

bozhidar20:10:14

Infrequently. I tend to press TAB a lot. 🙂