GNU bug report logs - #55865
[BUG] 28.1.50; Msg "Local variables list is not properly terminated." displayed when opening a file with line `print("Local Variable:")`

Previous Next

Package: emacs;

Reported by: Lin Sun <sunlin7 <at> hotmail.com>

Date: Thu, 9 Jun 2022 04:43:03 UTC

Severity: normal

Tags: wontfix

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 55865 in the body.
You can then email your comments to 55865 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#55865; Package emacs. (Thu, 09 Jun 2022 04:43:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Lin Sun <sunlin7 <at> hotmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 09 Jun 2022 04:43:03 GMT) Full text and rfc822 format available.

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

From: Lin Sun <sunlin7 <at> hotmail.com>
To: "bug-gnu-emacs <at> gnu.org" <bug-gnu-emacs <at> gnu.org>
Subject: [BUG] 28.1.50; Msg "Local variables list is not properly terminated."
 displayed when opening a file with line `print("Local Variable:")`
Date: Wed, 8 Jun 2022 23:02:18 +0000
Create a file /tmp/test.sh with one line:

print("Local Variables:")

Then open this test.sh file with emacs, a message appeared in the *Message* buffer:

>Local variables list is not properly terminated.

The message produced by function `hack-local-variables--find-variables`.

Please help to check it. Thanks

B.R.
Lin



Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#55865; Package emacs. (Thu, 09 Jun 2022 12:57:01 GMT) Full text and rfc822 format available.

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

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Lin Sun <sunlin7 <at> hotmail.com>
Cc: 55865 <at> debbugs.gnu.org
Subject: Re: bug#55865: [BUG] 28.1.50; Msg "Local variables list is not
 properly terminated." displayed when opening a file with line
 `print("Local Variable:")`
Date: Thu, 09 Jun 2022 14:56:09 +0200
Lin Sun <sunlin7 <at> hotmail.com> writes:

> Create a file /tmp/test.sh with one line:
>
> print("Local Variables:")
>
> Then open this test.sh file with emacs, a message appeared in the
> *Message* buffer:
>
>>Local variables list is not properly terminated.
>
> The message produced by function `hack-local-variables--find-variables`.
>
> Please help to check it. Thanks

I don't think there's anything to fix here -- Emacs makes a guess that
this is a Local Variable section, but then it turns out that it's not,
and it says so.

So if you don't want that message, you have to obfuscate the string.

Closing this bug report.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Added tag(s) wontfix. Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Thu, 09 Jun 2022 12:57:02 GMT) Full text and rfc822 format available.

bug closed, send any further explanations to 55865 <at> debbugs.gnu.org and Lin Sun <sunlin7 <at> hotmail.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Thu, 09 Jun 2022 12:57:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#55865; Package emacs. (Thu, 09 Jun 2022 16:05:02 GMT) Full text and rfc822 format available.

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

From: Lin Sun <sunlin7 <at> hotmail.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: "55865 <at> debbugs.gnu.org" <55865 <at> debbugs.gnu.org>
Subject: Re: bug#55865: [BUG] 28.1.50; Msg "Local variables list is not
 properly terminated." displayed when opening a file with line `print("Local
 Variable:")`
Date: Thu, 9 Jun 2022 16:04:42 +0000
[Message part 1 (text/plain, inline)]
Hi Lars,

Thank you for your explanation, and agree with you. Thank you.

B.R.
Lin
[Message part 2 (text/html, inline)]

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 08 Jul 2022 11:24:11 GMT) Full text and rfc822 format available.

bug unarchived. Request was from Rostislav Svoboda <rostislav.svoboda <at> gmail.com> to control <at> debbugs.gnu.org. (Wed, 23 Nov 2022 13:52:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#55865; Package emacs. (Wed, 23 Nov 2022 15:23:02 GMT) Full text and rfc822 format available.

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

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: Lin Sun <sunlin7 <at> hotmail.com>, 55865 <at> debbugs.gnu.org
Subject: Re: bug#55865: [BUG] 28.1.50; Msg "Local variables list is not
 properly terminated." displayed when opening a file with line
 `print("Local Variable:")`
Date: Wed, 23 Nov 2022 10:22:12 -0500
> I don't think there's anything to fix here -- Emacs makes a guess that
> this is a Local Variable section, but then it turns out that it's not,
> and it says so.
>
> So if you don't want that message, you have to obfuscate the string.

Indeed.  If there's something to fix here it's the relative lack
of information.
E.g. we could include in the message some info about the name of the
file in which we found the `Local Variables:` string (and its position
too, while at it).

We could also try and reduce the occurrence of such false positives
(e.g. by checking for the presence of `End:` or the presence of
the same prefix on the next line), but that would increase the
risk of emitting no message when the users do intend to write a `Local
Variables:` section but make a mistake writing it.


        Stefan





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Thu, 22 Dec 2022 12:24:12 GMT) Full text and rfc822 format available.

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

Previous Next


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