emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: tree-sitter crashes Emacs


From: Eli Zaretskii
Subject: Re: tree-sitter crashes Emacs
Date: Fri, 26 Apr 2024 17:53:56 +0300

> From: Joost Kremers <joostkremers@fastmail.fm>
> Date: Thu, 25 Apr 2024 08:58:45 +0200
> 
> A week ago or so, I opened a Python file in Emacs and saw Emacs crash hard.
> Bisecting my init file, I found that the culprit was tree-sitter. As it turns
> out, some change was made in tree-sitter that caused the ABI to change, and 
> when
> I upgraded my distro's tree-sitter package, the new ABI caused Emacs to crash.
> 
> There is a thread about this issue on the tree-sitter GitHub page:
> 
> https://github.com/tree-sitter/tree-sitter/issues/3296
> 
> The consensus there seems to be, however, that the current problem should not 
> be
> solved by the tree-sitter project, but rather by the relevant Linux
> distributions and/or by Emacs itself.
> 
> A bug has been opened for Arch Linux (the distro I'm using):
> 
> https://gitlab.archlinux.org/archlinux/packaging/packages/emacs/-/issues/2
> 
> That issue, however, is labelled with "status:waiting-upstream", which 
> suggests
> that nothing's going to happen until the tree-sitter project does something.
> Which is not going to happen, I fear, because the tree-sitter issue has been
> closed.
> 
> Since I haven't seen the issue mentioned here and given that it was suggested 
> it
> might be an Emacs issue, I wanted to ask the opinion of the maintainers: can
> this be considered an Emacs bug, or is it really something that should be 
> solved
> upstream?

We cannot do anything about this; see bug#70438.  The tree-sitter
developers changed the ABI without bumping up the ABI version.
Moreover, they think that's perfectly okay, since tree-sitter is
"still in version 0.x".  Because they didn't bump the ABI version,
Linux distros didn't bother to update Emacs they distribute, and the
result is crashes.

The only thing you can do is rebuild Emacs with the updated
tree-sitter (which is AFAIU the distros will do now , and will then
provide fixed packages), or downgrade your tree-sitter library to
version before the ABI change, 0.22.2.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]