unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eric Abrahamsen <eric@ericabrahamsen.net>
To: 35443@debbugs.gnu.org
Subject: bug#35443: 27.0.50; Gnus (nnimap) shows "ghost" messages in summary buffer
Date: Thu, 11 Jul 2019 13:28:37 -0700	[thread overview]
Message-ID: <87k1cotix6.fsf@ericabrahamsen.net> (raw)
In-Reply-To: <w6g1s1ovuew.fsf@kph.uni-mainz.de>

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> On 06/23/19 14:23 PM, Lars Ingebrigtsen wrote:
>> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>>
>>>> Did you get any further in fixing this nnimap parsing bug?
>>>
>>> Here's a whack at it. I tried to make sure that it would handle unwanted
>>> FETCH responses whether they came before or after (or in the middle of)
>>> the wanted FETCH responses, but I'm not in love with checking the header
>>> regexp this way.
>>
>> Well, I think it's OK...
>>
>>> Because this IMAP server feature is very closely focused on adding a
>>> flag in case of attachment (and because Gnus never explicitly requests
>>> this flag, though I'd sure like to in the future), another more targeted
>>> approach would be to simply delete any lines containing
>>> $Has\(No\)?Attachment, assuming that these FETCH responses will only
>>> take up one line.
>>
>> That sounds a bit brittle -- I'm sure there'll be other extensions like
>> this in the future to the IMAP protocol.
>>
>>> I've configured my local Dovecot with the offending setting, and will
>>> test it out for a bit.
>>
>> Great!
>
> (NB This patch is very broken and no one should use it; I'm still
> working on it. I want a proper parser!)

Turns out the dumb thing was simple: I was testing if the FETCH line was
followed by mail headers by looking for:

"\\(From\\|To\\|Subject\\|Date\\|Message-ID\\)"

Which is obviously insufficient. I've since changed it to:

"\\([A-Z][[:ascii:]-]+: \\)"

Which works better, but also seems susceptible to breakage due to
ignorance. A quick scan doesn't turn up any `mail-header-regexp'
variables or `this-is-a-mail-header-p' functions -- does the above
regexp seem reasonable?






  reply	other threads:[~2019-07-11 20:28 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-27  6:23 bug#35443: 27.0.50; Gnus (nnimap) shows "ghost" messages in summary buffer Ulrich Mueller
2019-04-27 15:03 ` Eric Abrahamsen
2019-04-27 15:49   ` Ulrich Mueller
2019-04-27 20:47     ` Eric Abrahamsen
2019-04-28  3:53       ` Ulrich Mueller
2019-04-29  0:43         ` Eric Abrahamsen
2019-05-09 17:27           ` Eric Abrahamsen
2019-05-09 19:03             ` Ulrich Mueller
2019-05-09 20:15               ` Eric Abrahamsen
2019-06-22 12:26                 ` Lars Ingebrigtsen
2019-06-22 16:27                   ` Eric Abrahamsen
2019-06-23 12:13                     ` Lars Ingebrigtsen
2019-06-23 16:55                       ` Eric Abrahamsen
2019-06-23 16:58                         ` Lars Ingebrigtsen
2019-06-23 17:23                           ` Eric Abrahamsen
2019-06-22 21:36                   ` Eric Abrahamsen
2019-06-23 12:23                     ` Lars Ingebrigtsen
2019-07-11 17:38                       ` Eric Abrahamsen
2019-07-11 20:28                         ` Eric Abrahamsen [this message]
2019-07-12 14:18                           ` Lars Ingebrigtsen
2019-07-12 16:50                             ` Eric Abrahamsen
2019-07-12 16:58                               ` Eric Abrahamsen
2019-07-14 16:19                               ` Eric Abrahamsen
2019-07-12 15:02                         ` Lars Ingebrigtsen
2019-07-15 17:45                           ` Eric Abrahamsen
2019-07-15 18:16                             ` Lars Ingebrigtsen
2019-05-07 21:14         ` Eric Abrahamsen
2019-05-08  7:07           ` Ulrich Mueller
2019-05-07 20:34 ` Eric Abrahamsen
2019-05-08 15:18   ` Ulrich Mueller

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=87k1cotix6.fsf@ericabrahamsen.net \
    --to=eric@ericabrahamsen.net \
    --cc=35443@debbugs.gnu.org \
    /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).