GNU bug report logs -
#68956
M-q → Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a predicate: nil
Previous Next
To reply to this bug, email your comments to 68956 AT debbugs.gnu.org.
There is no need to reopen the bug first.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Tue, 06 Feb 2024 17:34:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Dominique Quatravaux <dominique <at> quatravaux.org>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 06 Feb 2024 17:34:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
When invoking `prog-fill-reindent-defun' from inside a bash-ts-mode buffer,
an exception (regardless of where point is), an error is raised that reads
Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a
predicate: nil
Investigation reveals that `prog-fill-reindent-defun' calls
`treesit-node-match-p' with 'text as the second argument, which can only
succeed if `(assq 'text (assq 'bash treesit-thing-settings))' is non-nil;
whereas the corresponding setting for `treesit-thing-settings' prepared by
`bash-ts-mode', doesn't provide a value for 'text (only for 'sentence).
--
Dominique Quatravaux
dominique <at> quatravaux.org
[Message part 2 (text/html, inline)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Tue, 06 Feb 2024 17:45:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 68956 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
I had success applying the following workaround:
(advice-add 'bash-ts-mode
:after (lambda (&rest ignored)
(when-let ((bash-things (assq 'bash
treesit-thing-settings)))
(setf (alist-get 'text (cdr bash-things))
'(sentence)))))
Now M-q does the right thing for me everywhere in bash-ts-mode.
--
Dominique Quatravaux
dominique <at> quatravaux.org
[Message part 2 (text/html, inline)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Sat, 10 Feb 2024 08:55:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 68956 <at> debbugs.gnu.org (full text, mbox):
> From: Dominique Quatravaux <dominique <at> quatravaux.org>
> Date: Tue, 6 Feb 2024 18:32:27 +0100
>
> When invoking `prog-fill-reindent-defun' from inside a bash-ts-mode buffer, an exception (regardless of where
> point is), an error is raised that reads
>
> Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a predicate: nil
>
> Investigation reveals that `prog-fill-reindent-defun' calls `treesit-node-match-p' with 'text as the second
> argument, which can only succeed if `(assq 'text (assq 'bash treesit-thing-settings))' is non-nil; whereas the
> corresponding setting for `treesit-thing-settings' prepared by `bash-ts-mode', doesn't provide a value for 'text
> (only for 'sentence).
>
> I had success applying the following workaround:
>
> (advice-add 'bash-ts-mode
> :after (lambda (&rest ignored)
> (when-let ((bash-things (assq 'bash treesit-thing-settings)))
> (setf (alist-get 'text (cdr bash-things)) '(sentence)))))
>
> Now M-q does the right thing for me everywhere in bash-ts-mode.
Yuan, any comments or ideas?
Thanks.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Sat, 24 Feb 2024 09:57:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 68956 <at> debbugs.gnu.org (full text, mbox):
Ping! Yuan, any comments?
> Cc: 68956 <at> debbugs.gnu.org
> Date: Sat, 10 Feb 2024 10:44:01 +0200
> From: Eli Zaretskii <eliz <at> gnu.org>
>
> > From: Dominique Quatravaux <dominique <at> quatravaux.org>
> > Date: Tue, 6 Feb 2024 18:32:27 +0100
> >
> > When invoking `prog-fill-reindent-defun' from inside a bash-ts-mode buffer, an exception (regardless of where
> > point is), an error is raised that reads
> >
> > Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a predicate: nil
> >
> > Investigation reveals that `prog-fill-reindent-defun' calls `treesit-node-match-p' with 'text as the second
> > argument, which can only succeed if `(assq 'text (assq 'bash treesit-thing-settings))' is non-nil; whereas the
> > corresponding setting for `treesit-thing-settings' prepared by `bash-ts-mode', doesn't provide a value for 'text
> > (only for 'sentence).
> >
> > I had success applying the following workaround:
> >
> > (advice-add 'bash-ts-mode
> > :after (lambda (&rest ignored)
> > (when-let ((bash-things (assq 'bash treesit-thing-settings)))
> > (setf (alist-get 'text (cdr bash-things)) '(sentence)))))
> >
> > Now M-q does the right thing for me everywhere in bash-ts-mode.
>
> Yuan, any comments or ideas?
>
> Thanks.
>
>
>
>
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Wed, 10 Apr 2024 06:04:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 68956 <at> debbugs.gnu.org (full text, mbox):
[Adding the bug tracker back, forgot to replay-all]
> On Apr 8, 2024, at 8:42 PM, Yuan Fu <casouri <at> gmail.com> wrote:
>
>
> Eli Zaretskii <eliz <at> gnu.org> writes:
>
>>> Cc: 68956 <at> debbugs.gnu.org
>>> Date: Sat, 10 Feb 2024 10:44:01 +0200
>>> From: Eli Zaretskii <eliz <at> gnu.org>
>>>
>>>> From: Dominique Quatravaux <dominique <at> quatravaux.org>
>>>> Date: Tue, 6 Feb 2024 18:32:27 +0100
>>>>
>>>> When invoking `prog-fill-reindent-defun' from inside a bash-ts-mode buffer, an exception (regardless of where
>>>> point is), an error is raised that reads
>>>>
>>>> Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a predicate: nil
>>>>
>>>> Investigation reveals that `prog-fill-reindent-defun' calls `treesit-node-match-p' with 'text as the second
>>>> argument, which can only succeed if `(assq 'text (assq 'bash treesit-thing-settings))' is non-nil; whereas the
>>>> corresponding setting for `treesit-thing-settings' prepared by `bash-ts-mode', doesn't provide a value for 'text
>>>> (only for 'sentence).
>>>>
>>>> I had success applying the following workaround:
>>>>
>>>> (advice-add 'bash-ts-mode
>>>> :after (lambda (&rest ignored)
>>>> (when-let ((bash-things (assq 'bash treesit-thing-settings)))
>>>> (setf (alist-get 'text (cdr bash-things)) '(sentence)))))
>>>>
>>>> Now M-q does the right thing for me everywhere in bash-ts-mode.
>>>
>>> Yuan, any comments or ideas?
>>>
>>> Thanks.
>
> Sorry for the delay. Dominique, what version are you using? I can see
> that this is fixed on master[1], but not on emacs-29, perhaps due to
> the size of the change.
>
> [1] b392d05089014ac6d41e35a016d46f496964f879
>
> Yuan
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Wed, 10 Apr 2024 10:53:03 GMT)
Full text and
rfc822 format available.
Message #20 received at 68956 <at> debbugs.gnu.org (full text, mbox):
> From: Yuan Fu <casouri <at> gmail.com>
> Date: Tue, 9 Apr 2024 23:03:21 -0700
> Cc: 68956 <at> debbugs.gnu.org
>
> [Adding the bug tracker back, forgot to replay-all]
And it might be a good idea to add Dominique as well ;-)
>
> > On Apr 8, 2024, at 8:42 PM, Yuan Fu <casouri <at> gmail.com> wrote:
> >
> >
> > Eli Zaretskii <eliz <at> gnu.org> writes:
> >
> >>> Cc: 68956 <at> debbugs.gnu.org
> >>> Date: Sat, 10 Feb 2024 10:44:01 +0200
> >>> From: Eli Zaretskii <eliz <at> gnu.org>
> >>>
> >>>> From: Dominique Quatravaux <dominique <at> quatravaux.org>
> >>>> Date: Tue, 6 Feb 2024 18:32:27 +0100
> >>>>
> >>>> When invoking `prog-fill-reindent-defun' from inside a bash-ts-mode buffer, an exception (regardless of where
> >>>> point is), an error is raised that reads
> >>>>
> >>>> Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a predicate: nil
> >>>>
> >>>> Investigation reveals that `prog-fill-reindent-defun' calls `treesit-node-match-p' with 'text as the second
> >>>> argument, which can only succeed if `(assq 'text (assq 'bash treesit-thing-settings))' is non-nil; whereas the
> >>>> corresponding setting for `treesit-thing-settings' prepared by `bash-ts-mode', doesn't provide a value for 'text
> >>>> (only for 'sentence).
> >>>>
> >>>> I had success applying the following workaround:
> >>>>
> >>>> (advice-add 'bash-ts-mode
> >>>> :after (lambda (&rest ignored)
> >>>> (when-let ((bash-things (assq 'bash treesit-thing-settings)))
> >>>> (setf (alist-get 'text (cdr bash-things)) '(sentence)))))
> >>>>
> >>>> Now M-q does the right thing for me everywhere in bash-ts-mode.
> >>>
> >>> Yuan, any comments or ideas?
> >>>
> >>> Thanks.
> >
> > Sorry for the delay. Dominique, what version are you using? I can see
> > that this is fixed on master[1], but not on emacs-29, perhaps due to
> > the size of the change.
> >
> > [1] b392d05089014ac6d41e35a016d46f496964f879
> >
> > Yuan
>
>
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Sat, 20 Apr 2024 07:46:02 GMT)
Full text and
rfc822 format available.
Message #23 received at 68956 <at> debbugs.gnu.org (full text, mbox):
Ping! Dominique, could you please answer Yuan's question below?
> Cc: 68956 <at> debbugs.gnu.org
> Date: Wed, 10 Apr 2024 13:51:33 +0300
> From: Eli Zaretskii <eliz <at> gnu.org>
>
> > From: Yuan Fu <casouri <at> gmail.com>
> > Date: Tue, 9 Apr 2024 23:03:21 -0700
> > Cc: 68956 <at> debbugs.gnu.org
> >
> > [Adding the bug tracker back, forgot to replay-all]
>
> And it might be a good idea to add Dominique as well ;-)
>
> >
> > > On Apr 8, 2024, at 8:42 PM, Yuan Fu <casouri <at> gmail.com> wrote:
> > >
> > >
> > > Eli Zaretskii <eliz <at> gnu.org> writes:
> > >
> > >>> Cc: 68956 <at> debbugs.gnu.org
> > >>> Date: Sat, 10 Feb 2024 10:44:01 +0200
> > >>> From: Eli Zaretskii <eliz <at> gnu.org>
> > >>>
> > >>>> From: Dominique Quatravaux <dominique <at> quatravaux.org>
> > >>>> Date: Tue, 6 Feb 2024 18:32:27 +0100
> > >>>>
> > >>>> When invoking `prog-fill-reindent-defun' from inside a bash-ts-mode buffer, an exception (regardless of where
> > >>>> point is), an error is raised that reads
> > >>>>
> > >>>> Invalid predicate, see ‘treesit-thing-settings’ for valid forms for a predicate: nil
> > >>>>
> > >>>> Investigation reveals that `prog-fill-reindent-defun' calls `treesit-node-match-p' with 'text as the second
> > >>>> argument, which can only succeed if `(assq 'text (assq 'bash treesit-thing-settings))' is non-nil; whereas the
> > >>>> corresponding setting for `treesit-thing-settings' prepared by `bash-ts-mode', doesn't provide a value for 'text
> > >>>> (only for 'sentence).
> > >>>>
> > >>>> I had success applying the following workaround:
> > >>>>
> > >>>> (advice-add 'bash-ts-mode
> > >>>> :after (lambda (&rest ignored)
> > >>>> (when-let ((bash-things (assq 'bash treesit-thing-settings)))
> > >>>> (setf (alist-get 'text (cdr bash-things)) '(sentence)))))
> > >>>>
> > >>>> Now M-q does the right thing for me everywhere in bash-ts-mode.
> > >>>
> > >>> Yuan, any comments or ideas?
> > >>>
> > >>> Thanks.
> > >
> > > Sorry for the delay. Dominique, what version are you using? I can see
> > > that this is fixed on master[1], but not on emacs-29, perhaps due to
> > > the size of the change.
> > >
> > > [1] b392d05089014ac6d41e35a016d46f496964f879
> > >
> > > Yuan
> >
> >
>
>
>
>
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#68956
; Package
emacs
.
(Mon, 22 Apr 2024 10:55:03 GMT)
Full text and
rfc822 format available.
Message #26 received at 68956 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Le sam. 20 avr. 2024 à 09:45, Eli Zaretskii <eliz <at> gnu.org> a écrit :
> Ping! Dominique, could you please answer Yuan's question below?
>
Dear Eli, dear Yuan, I just rebuilt my Emacs to version
4d9629b087fe6df941b553c6931b2f8996901e21 and indeed M-q doesn't crash
anymore.
Please feel free to close bug#68956.
Many thanks,
--
Dominique Quatravaux
dominique <at> quatravaux.org
[Message part 2 (text/html, inline)]
Reply sent
to
Eli Zaretskii <eliz <at> gnu.org>
:
You have taken responsibility.
(Mon, 22 Apr 2024 10:57:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Dominique Quatravaux <dominique <at> quatravaux.org>
:
bug acknowledged by developer.
(Mon, 22 Apr 2024 10:57:02 GMT)
Full text and
rfc822 format available.
Message #31 received at 68956-done <at> debbugs.gnu.org (full text, mbox):
> From: Dominique Quatravaux <dominique <at> quatravaux.org>
> Date: Mon, 22 Apr 2024 12:53:52 +0200
> Cc: casouri <at> gmail.com, 68956 <at> debbugs.gnu.org
>
> Le sam. 20 avr. 2024 à 09:45, Eli Zaretskii <eliz <at> gnu.org> a écrit :
>
> Ping! Dominique, could you please answer Yuan's question below?
>
> Dear Eli, dear Yuan, I just rebuilt my Emacs to version 4d9629b087fe6df941b553c6931b2f8996901e21 and
> indeed M-q doesn't crash anymore.
>
> Please feel free to close bug#68956.
Thanks, closing.
This bug report was last modified 12 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.