GNU bug report logs - #64647
treesit-query-error due to a recent change to tree-sitter-javascript grammar definition

Previous Next

Package: emacs;

Reported by: Vincenzo Pupillo <v.pupillo <at> gmail.com>

Date: Sat, 15 Jul 2023 12:35:02 UTC

Severity: normal

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #17 received at 64647 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Theodor Thornhill <theo <at> thornhill.no>
Cc: 64647 <at> debbugs.gnu.org, v.pupillo <at> gmail.com, jostein <at> kjonigsen.net
Subject: Re: bug#64647: treesit-query-error due to a recent change to
 tree-sitter-javascript grammar definition
Date: Sat, 15 Jul 2023 22:16:42 +0300
> From: Theodor Thornhill <theo <at> thornhill.no>
> Cc: Vincenzo Pupillo <v.pupillo <at> gmail.com>,  Jostein Kjonigsen
>  <jostein <at> kjonigsen.net>,  64647 <at> debbugs.gnu.org
> Date: Sat, 15 Jul 2023 19:54:03 +0200
> 
> Eli Zaretskii <eliz <at> gnu.org> writes:
> 
> >> The patch in attachment fixes both problems.
> >
> > Will the patch work with the grammar libraries before the recent
> > change?
> >
> 
> It will introduce regressions, but the patch itself is a change for the
> better, both in emacs land and in the grammar itself. 

What kinds of regressions?

> I don't disagree, but I think this is a difficult problem to solve, but
> with an easy cop-out solution that most other implementors use - just
> refer to the last supported commit. We've had some discussions on this,
> but IIRC we never settled on anything. Personally, I think a
> 
> ;;; Tree-sitter-version: bb1f97b643b77fc1f082d621bf533b4b14cf0c30
> 
> header may be the simplest way to at least signal some awareness
> here. That way the auto install mechanism can pull that hash directly
> and we can ensure some sort of compatibility checking.
> 
> What do you think?

I think what I wrote: that we should try to make our modes work with
reasonably old versions of the grammars, if that is practical.  While
in general it could be a very difficult, if not impossible, to achieve
that, the question is whether this particular issue can be solved in
that manner.  If it can, we should do it.




This bug report was last modified 2 years and 18 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.