GNU bug report logs -
#26796
26.0.50; (2 characters) is usually wrong
Previous Next
Reported by: Lars Ingebrigtsen <larsi <at> gnus.org>
Date: Sat, 6 May 2017 09:51:01 UTC
Severity: normal
Found in version 26.0.50
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 26796 in the body.
You can then email your comments to 26796 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 09:51:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Lars Ingebrigtsen <larsi <at> gnus.org>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Sat, 06 May 2017 09:51:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
To reproduce, open a file, type in "á" and save the file. Emacs will
now say (if you're a utf-8 kind of person)
Wrote ‘/tmp/a’ (2 characters)
which is wrong, since there's just one character in the buffer. Perhaps
saying "(2 bytes)" will be more helpful?
(I'd rather Emacs default to not saying anything about the length of the
file saved at all by default, since it's just noise to me (and I'll
assume to most people).)
In GNU Emacs 26.0.50 (build 3, x86_64-pc-linux-gnu, GTK+ Version 3.14.5)
of 2017-04-24 built on stories
Repository revision: a1f93c1dfa53dbe007faa09ab0c6e913e86e3ffe
Windowing system distributor 'The X.Org Foundation', version 11.0.11604000
System Description: Debian GNU/Linux 8.7 (jessie)
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 10:34:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 26796 <at> debbugs.gnu.org (full text, mbox):
> From: Lars Ingebrigtsen <larsi <at> gnus.org>
> Date: Sat, 06 May 2017 11:49:55 +0200
>
> To reproduce, open a file, type in "á" and save the file. Emacs will
> now say (if you're a utf-8 kind of person)
>
> Wrote ‘/tmp/a’ (2 characters)
>
> which is wrong, since there's just one character in the buffer.
I see "1 characters" here. I think the result depends on who you type
the above: if there are two characters, a followed by ́, then the file
really has 2 characters, and they are only shown as one on display.
Try "C-u C-x =" to see what you have in the buffer.
> Perhaps saying "(2 bytes)" will be more helpful?
I really doubt that: Emacs users tend to think in terms of characters
than in terms of bytes.
Reply sent
to
Lars Ingebrigtsen <larsi <at> gnus.org>
:
You have taken responsibility.
(Sat, 06 May 2017 10:39:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Lars Ingebrigtsen <larsi <at> gnus.org>
:
bug acknowledged by developer.
(Sat, 06 May 2017 10:39:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 26796-done <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
> I see "1 characters" here. I think the result depends on who you type
> the above: if there are two characters, a followed by ́, then the file
> really has 2 characters, and they are only shown as one on display.
> Try "C-u C-x =" to see what you have in the buffer.
No, it was an á, but the problem was instead that I apparently had
fumbled and added a newline before saving? Hm. Sorry for the noise;
closing.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 10:46:02 GMT)
Full text and
rfc822 format available.
Message #16 received at 26796 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> Perhaps saying "(2 bytes)" will be more helpful?
>
> I really doubt that: Emacs users tend to think in terms of characters
> than in terms of bytes.
But this is questionable, at least:
(with-temp-buffer (set-buffer-multibyte nil) (insert-file-contents "~/rms.jpg") (write-region (point-min) (point-max) "/tmp/a.jpg"))
Wrote ‘/tmp/a.jpg’ (889 characters)
There are no characters in a JPEG file; it's all bytes.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 11:08:01 GMT)
Full text and
rfc822 format available.
Message #19 received at 26796 <at> debbugs.gnu.org (full text, mbox):
> From: Lars Ingebrigtsen <larsi <at> gnus.org>
> Cc: 26796 <at> debbugs.gnu.org
> Date: Sat, 06 May 2017 12:45:45 +0200
>
> But this is questionable, at least:
>
> (with-temp-buffer (set-buffer-multibyte nil) (insert-file-contents "~/rms.jpg") (write-region (point-min) (point-max) "/tmp/a.jpg"))
> Wrote ‘/tmp/a.jpg’ (889 characters)
>
> There are no characters in a JPEG file; it's all bytes.
Each byte is a character in this case, right?
Anyway, since you don't like this feature, it's clear that you can
come up with many examples where you don't like the result. People
who do like it will most probably disagree.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 12:16:01 GMT)
Full text and
rfc822 format available.
Message #22 received at 26796 <at> debbugs.gnu.org (full text, mbox):
Lars Ingebrigtsen <larsi <at> gnus.org> writes:
> (I'd rather Emacs default to not saying anything about the length of the
> file saved at all by default, since it's just noise to me (and I'll
> assume to most people).)
Eli Zaretskii <eliz <at> gnu.org> writes:
> Anyway, since you don't like this feature, it's clear that you can
> come up with many examples where you don't like the result. People
> who do like it will most probably disagree.
Actually this reminds I was planning on reverting this feature entirely,
I haven't seen anyone say they like it (the bug reporter who initiated
this feature never responded:
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=354#81) whereas quite a
few seem to actively dislike it.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 14:20:01 GMT)
Full text and
rfc822 format available.
Message #25 received at 26796 <at> debbugs.gnu.org (full text, mbox):
> From: npostavs <at> users.sourceforge.net
> Date: Sat, 06 May 2017 08:16:53 -0400
> Cc: 26796 <at> debbugs.gnu.org
>
> Actually this reminds I was planning on reverting this feature entirely,
Since it's already implemented, maybe just make it optional, by
default off.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sat, 06 May 2017 17:21:02 GMT)
Full text and
rfc822 format available.
Message #28 received at 26796 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> From: npostavs <at> users.sourceforge.net
>> Date: Sat, 06 May 2017 08:16:53 -0400
>> Cc: 26796 <at> debbugs.gnu.org
>>
>> Actually this reminds I was planning on reverting this feature entirely,
>
> Since it's already implemented, maybe just make it optional, by
> default off.
I'm not sure the added complexity is worth it for a feature that
probably nobody will bother using...
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Sun, 07 May 2017 01:12:02 GMT)
Full text and
rfc822 format available.
Message #31 received at 26796 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Appending " (NNNN characters)" to the "Wrote FOO" messages appears to be
unpopular and at times confusing. At least it should be off by default, so I
installed the attached. It'd be fine with me if we removed them entirely.
[0001-New-var-write-region-verbose-default-nil.patch (text/x-diff, attachment)]
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Mon, 08 May 2017 05:03:02 GMT)
Full text and
rfc822 format available.
Message #34 received at 26796 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii <eliz <at> gnu.org> writes:
>> From: npostavs <at> users.sourceforge.net
>> Date: Sat, 06 May 2017 08:16:53 -0400
>> Cc: 26796 <at> debbugs.gnu.org
>>
>> Actually this reminds I was planning on reverting this feature entirely,
>
> Since it's already implemented, maybe just make it optional, by
> default off.
Was there any reason to implement it in the first place?
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Mon, 08 May 2017 14:35:02 GMT)
Full text and
rfc822 format available.
Message #37 received at 26796 <at> debbugs.gnu.org (full text, mbox):
> From: Mark Oteiza <mvoteiza <at> udel.edu>
> Cc: npostavs <at> users.sourceforge.net, larsi <at> gnus.org, 26796 <at> debbugs.gnu.org
> Date: Mon, 08 May 2017 01:02:27 -0400
>
> Was there any reason to implement it in the first place?
Seems we are back at the discussion we had starting here:
http://lists.gnu.org/archive/html/emacs-devel/2017-04/msg00219.html
;-)
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Mon, 08 May 2017 16:01:02 GMT)
Full text and
rfc822 format available.
Message #40 received at 26796 <at> debbugs.gnu.org (full text, mbox):
Eli Zaretskii wrote:
>> Was there any reason to implement it in the first place?
>
> Seems we are back at the discussion we had starting here:
>
> http://lists.gnu.org/archive/html/emacs-devel/2017-04/msg00219.html
In which, if I read right, literally no-one was in favour of the feature?
A feature that several people have now spent time debugging, tweaking,
and documenting, and which will have to be supported going forwards.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Mon, 08 May 2017 16:09:01 GMT)
Full text and
rfc822 format available.
Message #43 received at 26796 <at> debbugs.gnu.org (full text, mbox):
> From: Glenn Morris <rgm <at> gnu.org>
> Cc: Mark Oteiza <mvoteiza <at> udel.edu>, larsi <at> gnus.org, 26796 <at> debbugs.gnu.org, npostavs <at> users.sourceforge.net
> Date: Mon, 08 May 2017 11:59:52 -0400
>
> Eli Zaretskii wrote:
>
> >> Was there any reason to implement it in the first place?
> >
> > Seems we are back at the discussion we had starting here:
> >
> > http://lists.gnu.org/archive/html/emacs-devel/2017-04/msg00219.html
>
> In which, if I read right, literally no-one was in favour of the feature?
> A feature that several people have now spent time debugging, tweaking,
> and documenting, and which will have to be supported going forwards.
Is this a complaint about something I did? Just wondering.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Tue, 09 May 2017 00:42:02 GMT)
Full text and
rfc822 format available.
Message #46 received at 26796 <at> debbugs.gnu.org (full text, mbox):
On 08/05/17 at 07:07pm, Eli Zaretskii wrote:
> > From: Glenn Morris <rgm <at> gnu.org>
> > Cc: Mark Oteiza <mvoteiza <at> udel.edu>, larsi <at> gnus.org, 26796 <at> debbugs.gnu.org, npostavs <at> users.sourceforge.net
> > Date: Mon, 08 May 2017 11:59:52 -0400
> >
> > Eli Zaretskii wrote:
> >
> > >> Was there any reason to implement it in the first place?
> > >
> > > Seems we are back at the discussion we had starting here:
> > >
> > > http://lists.gnu.org/archive/html/emacs-devel/2017-04/msg00219.html
> >
> > In which, if I read right, literally no-one was in favour of the feature?
> > A feature that several people have now spent time debugging, tweaking,
> > and documenting, and which will have to be supported going forwards.
>
> Is this a complaint about something I did? Just wondering.
I'm just here to complain that everything stemming from this change,
including the bikeshedding about if and how filenames in the message
should be quoted (which is just more waste of space) hasn't been
reverted yet.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#26796
; Package
emacs
.
(Tue, 09 May 2017 04:38:01 GMT)
Full text and
rfc822 format available.
Message #49 received at 26796 <at> debbugs.gnu.org (full text, mbox):
unarchive 354
tags 354 = wontfix
quit
Glenn Morris <rgm <at> gnu.org> writes:
> Eli Zaretskii wrote:
>
>>> Was there any reason to implement it in the first place?
>>
>> Seems we are back at the discussion we had starting here:
>>
>> http://lists.gnu.org/archive/html/emacs-devel/2017-04/msg00219.html
>
> In which, if I read right, literally no-one was in favour of the feature?
> A feature that several people have now spent time debugging, tweaking,
> and documenting, and which will have to be supported going forwards.
My only defence is that everyone seemed to think it was a good idea
*before* I merged it. In hindsight I should have reverted this much
sooner, but anyway, it's done now [1: daaec72a82].
[1: daaec72a82]: 2017-05-08 23:28:32 -0400
Revert "Output number of characters added to file (Bug#354)"
http://git.savannah.gnu.org/cgit/emacs.git/commit/?id=daaec72a82e76f916e639acb51a8ad602433e8a9
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Tue, 06 Jun 2017 11:24:06 GMT)
Full text and
rfc822 format available.
This bug report was last modified 8 years and 101 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.