Fork me on GitHub
#spacemacs
<
2021-02-05
>
mccraigmccraig11:02:35

so, frustrated by spac/emacs instability (generally poor performance, occasional crashes, and hangs on wide files and large repl output), i went as far as trying vscode for a couple of weeks, and it's not bad. it's certainly a lot more stable, and there are loads of good extensions. but CIDER is quite a lot better than calva, and pervasive helm is so much better than vscode's grab-bag of different UI for different nav tasks, and emacs windows and layouts are just great &c so i'm wondering - has anyone had any success with making spac/emacs (on macos) more stable ? e.g. are some versions better than others wrt crashing and wide files, are there any helpful tricks ?

☝️ 6
bmaddy18:02:30

Thanks for the report on vscode. I was thinking about trying that out for similar reasons. I know a lot of the Clojure community is using intellij. I don't know if that's because it's really good or just people coming from java are familiar with it. Have you tried that one?

mccraigmccraig19:02:24

i've used intellij for java plenty... it has great refactoring support, but i don't like it 😃

mccraigmccraig19:02:45

i've gone back to spacemacs for now - the CIDER test loop is so much better i'm just more productive. i'm also trying a new emacs build - https://github.com/d12frosted/homebrew-emacs-plus from homebrew (i was previously on railwaycat) so we'll see how that goes

bmaddy20:02:07

Too bad, I was hoping Cursive would be as good as cider. fwiw, I haven't had too many performance issues with https://emacsformacosx.com/. Or, at least, I blame my performance issues on the number of web browser tabs I have open. 🙂

practicalli-john22:02:23

Cursive seems relevant if you have a deep knowledge of using IntellJ and mostly code by static analysis of code rather than REPL. I have met quite a few developers using Cursive that never used the REPL. Calva is focusing a lot more on static analysis as it's building on LSP. I wonder if the repl will be used less with Calva too. I haven't found anything better than Cider for doing REPL driven development, although Conjure plugin for NeoVim is very good. So apparently is vim-iced.

mccraigmccraig22:02:46

i haven't tried to use cursive @U067Q76EP, so i can't comment on it - i'm pretty clear i don't want to use intellij, so i've not bothered with it. others may feel differently ofc

👍 3
mccraigmccraig22:02:40

i'm generallly very happy with CIDER's functionality - it's just emacs instability that winds me up sometimes

mccraigmccraig22:02:28

calva does use lsp, but lots of stuff still seems to require a repl @U05254DQM . its repl is ok, and code navigation through definitions and references etc is really nice. i tried to use it for a test driven workflow though, and the test runner feedback is quite deficient compared to CIDER's

mccraigmccraig22:02:50

i might give conjure and vim-iced a spin... i've never really tried serious editing with vim, but stuff like this makes me want to try it out : http://takac.github.io/2013/01/30/vim-grammar/

grazfather00:02:55

let us know what you think about vim iced. I somehow only learned about it today (reading the babashka book). I had been using vim-fireplace. Cider is certainly much better for repl integration

prnc15:02:44

I’ve seen reports of DOOM Emacs being better in those areas, haven’t tried myself

emilaasa07:02:22

Conjure and neovim works well on a tortured macbook pro at the moment.

emilaasa07:02:27

I haven't played around with lsp too much yet, we'll see what happens in a large codebase with lsp.

emilaasa07:02:02

The primary reason I use neovim instead of spacemacs or cursive is the performance which is great.

Yehonathan Sharvit19:02:00

How could it be that Emacs is not stable?

practicalli-john19:02:00

For me, Emacs has stable on Linux for the last decade. Even running nightly builds of Emacs 28 last year was stable for the few months I used them. I wonder if it's some other factor?

Yehonathan Sharvit19:02:44

Isn't it supposed to be one of the most stable editor out there?

practicalli-john19:02:09

Emacs has been stable on Linux for me for the last decade, not sure how much more stable you are looking for. Most likely causes of instability are packages or the distribution of Emacs used conflicting with changes to an operating system. Its not that surprising to see issues with those running the new hardware and software for MacOSX, as thats a really big change. As MacOSX is a commercial operating system, its probably not surprising that less testing gets done upon it. This could be a source of issues.

mccraigmccraig20:02:17

@U0L91U7A8 :man-shrugging: i was having hard crashes every week or so, not sure why. performance is awful when a repl dumps a load of stuff, leading to pauses and sometimes crashes, and wide lines also lead to very poor performance

mccraigmccraig20:02:14

I'm trying a different build now... i was on railwaycats, now trying brew/emacs+ ... will see if that's any better

Yehonathan Sharvit20:02:55

@U05254DQM is there a way to limit the size of the REPL buffer size?

practicalli-john20:02:37

cider-repl-buffer-size-limit with an integer value will limit the repl output. 1000 should be okay. I have it set to 100 as I dont use the REPL buffer in Cider directly It can either be a setq in dotspacemacs/user-config or add it as a clojure layer variable

(clojure :variables
              clojure-backend 'cider
              clojure-enable-linters 'clj-kondo
              clojure-toplevel-inside-comment-form t
              cider-overlays-use-font-lock t
              cider-repl-buffer-size-limit 100)

practicalli-john20:02:03

Avoid sending logs to the REPL buffer, especially if the logs generate proper log objects or very long strings... It wont take many lines of those to start to slow down Emacs.

Yehonathan Sharvit06:02:58

1. cider-repl-buffer-size-limit doesn’t work 2. How do we avoid sending logs to the REPL buffer?

practicalli-john09:02:18

There is a suggestion in #emacs as to stable versions to use on MacOSX https://clojurians.slack.com/archives/C099W16KZ/p1613009517053300

mccraigmccraig09:02:14

thanks @U05254DQM - i've been using the brew/emacs+ bottled version for the past few days, and haven't had any crashes yet

👍 4
grazfather18:02:04

I am with you. I like emacs but the hangs, crashes, and general slowness are hard to deal with. I still find if i need to get something edited quickly it’s a lot nicer just using Vim

👍 6