Hello fellow Emacs enthusiasts,

I’m reaching out to see if there’s anyone here who’s successfully integrated a modern development environment within Emacs for Python programming. Specifically, I’m interested in a setup that incorporates eglot, tree-sitter and company.

I’ve encountered a significant issue: whenever I enable python-ts-mode, Emacs consumes all my system’s memory and crashes. While I’ve managed to use a more basic setup that limits tree-sitter to syntax highlighting only, I can’t shake the feeling that I’m missing out on some great functionality.

To help with investigation:

  • I am running on a Mac
  • The bare minimum to reproduce this problem is on the following gist: https://gist.github.com/hnarayanan/a6397d6723fce19e2802d4305071e611
  • I happen to use Emacs from MacPorts, but to double-check, I also attempted to download it from https://emacsformacosx.com and it crashed in the same way
  • This seems to happen independent of the language server used in the backend. I intend on using python-lsp-server, but it fails even if I don’t have it installed.

Has anyone faced a similar problem and found a solution? Perhaps I am doing something very wrong with my config? I’m eager to learn from your experiences and would greatly appreciate any advice or tips you can offer.

Thank you!

You are viewing a single thread.
View all comments View context
1 point

Well, they used to call it “Eight Megabytes and Constantly Swapping” :-) One could only wish, now!

Seriously, I’ve also seen some poor behavior with ts-mode and ts-folding also, maybe with python or yaml, ending in a hang or crash, not sure of specifics yet. I’ll pay better attention next time.

permalink
report
parent
reply

Emacs

!emacs@communick.news

Create post

A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!

Get Emacs

  • Windows
  • Mac OS X
  • GNU/Linux and BSD (Just get it from your distribution’s package manager)

Rules

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for “emacs” and “vi” link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

Community stats

  • 18

    Monthly active users

  • 562

    Posts

  • 2.4K

    Comments