unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Morgan Willcock <morgan@ice9.digital>
To: Eli Zaretskii <eliz@gnu.org>
Cc: Po Lu <luangruo@yahoo.com>, 64487@debbugs.gnu.org
Subject: bug#64487: 29.0.92; Another tree-sitter warning inside Custom
Date: Mon, 26 Feb 2024 11:13:40 +0000	[thread overview]
Message-ID: <86h6hvzdej.fsf@ice9.digital> (raw)
In-Reply-To: <83a5w9ieti.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 06 Jul 2023 12:12:25 +0300")

Eli Zaretskii <eliz@gnu.org> writes:

>> Date: Thu, 06 Jul 2023 14:56:44 +0800
>> From:  Po Lu via "Bug reports for GNU Emacs,
>>  the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>> 
>> Type M-x customize RET.  Click Programming and then Languages.  A
>> *Warnings* buffer will be displayed containing the following message:
>> 
>>   Warning (treesit): Cannot activate tree-sitter, because language
>>   grammar for ruby is unavailable (not-found): (libtree-sitter-ruby
>>   libtree-sitter-ruby.0 libtree-sitter-ruby.0.0 libtree-sitter-ruby.so
>>   libtree-sitter-ruby.so.0 libtree-sitter-ruby.so.0.0) No such file or
>>   directory
>
> When you customize a group, Custom loads all the packages that belong
> to the group.  So in this case it loads ruby-ts-mode, and you get the
> warning.
>
>> Can't these messages only be displayed when a tree-sitter major mode is
>> enabled, as opposed to whenever the file implementing the major mode is
>> loaded?
>
> Emacs 29 deliberately checks for the grammar's availability when the
> package is loaded, to give users a prominent indication that the
> loaded package will not work.  This won't change in Emacs 29, but
> maybe as part of rethinking this after releasing Emacs 29 we could
> improve the situation with customizing a group as well.
>
> Anyway, the warning is just a warning, and is otherwise harmless.  It
> also only appears when Emacs has been built with tree-sitter, but the
> grammar libraries required by some *-ts-mode's are not installed.

I don't think this situation will be particularly rare for people who
choose to download the pre-built Windows binaries.

And I imagine that people choosing to acquire and run the program this
way (possibly because they do not know how to build the program
themselves) would probably be confused as to why the "out-of-the-box"
experience is generating warnings for features they are not actively
trying to use.

-- 
Morgan Willcock





  reply	other threads:[~2024-02-26 11:13 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <871qhlmssz.fsf.ref@yahoo.com>
2023-07-06  6:56 ` bug#64487: 29.0.92; Another tree-sitter warning inside Custom Po Lu via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-07-06  9:12   ` Eli Zaretskii
2024-02-26 11:13     ` Morgan Willcock [this message]
2024-02-26 16:25     ` Dmitry Gutov
2024-02-26 16:49       ` Eli Zaretskii
2024-02-26 16:55         ` Dmitry Gutov
2024-02-26 17:02           ` Eli Zaretskii
2024-02-27  4:23             ` Dmitry Gutov
2024-02-27  8:11               ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86h6hvzdej.fsf@ice9.digital \
    --to=morgan@ice9.digital \
    --cc=64487@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=luangruo@yahoo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).