GNU bug report logs -
#20610
25.0.50; Gnus fancy mail splitting not working anymore
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 20610 in the body.
You can then email your comments to 20610 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#20610
; Package
emacs
.
(Tue, 19 May 2015 12:41:03 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Sebastien Vauban <sva-news <at> mygooglest.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 19 May 2015 12:41:03 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
While "fancy mail splitting" (section 6.4.6 of the manual) with the
`gnus-private' attribute of BBDB [1] works perfectly -- for years! --
under (Windows) Emacs 24.5 (and many previous versions), it stops
working when using Emacs 25.0.50 [2]... while (let's be explicit!) the
`.gnus' file stays strictly the same.
Here a minimal working configuration file for Emacs 24.5:
--8<---------------cut here---------------start------------->8---
(require 'gnus)
(require 'auth-source)
(setq auth-source-debug t)
;; Configure incoming mail.
(setq gnus-select-method
'(nnimap "mail"
(nnimap-address "mail")
(nnimap-server-port 993)
(nnimap-stream ssl)))
;; Name(s) of IMAP mailboxes to split mail from.
(setq nnimap-inbox "INBOX")
;; The first match in `nnmail-split-rule' found will be used.
(setq nnmail-crosspost nil)
;; BBDB (Big Brother DataBase) is loaded from my `.emacs' file.
(require 'bbdb-gnus)
;; Split function to use (sorting mails into groups using BBDB).
(setq nnimap-split-methods 'nnimap-split-fancy)
;; Specify how to split mail.
(setq nnimap-split-fancy
'(| ; split to the *first* match
;; Invoke BBDB.
(: (lambda ()
(car (bbdb/gnus-split-method))))
;; Catch spam.
("X-Spam-Status" "[Yy]es"
"INBOX.Spam")
;; Undecided.
"INBOX"))
;; For records which don't have `gnus-private' set, the rules in
;; `split-fancy' are invoked.
(setq bbdb/gnus-split-default-group nil)
;;; .gnus ends here
--8<---------------cut here---------------end--------------->8---
I've tried numerous changes (for hours), such as:
- renaming `nnimap-split-methods' to `nnmail-split-methods' and
`nnimap-split-fancy' to `nnmail-split-fancy', or
- moving `nnimap-inbox' and `nnimap-split-methods' (without the `setq'
and without the quotes) inside the definition of `gnus-select-method',
with no success. In those 2 latter cases, it even stops working within
Emacs 24.5, so this seems not to be the right path...
Best regards.
[1] ~/.emacs.d/elpa/bbdb-20140830.2031/bbdb-gnus.elc
[2] GNU Emacs 25.0.50.1 (i686-pc-mingw32) of 2015-05-08 on LEG570
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Tue, 19 May 2015 17:36:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 20610 <at> debbugs.gnu.org (full text, mbox):
> While "fancy mail splitting" (section 6.4.6 of the manual) with the
> `gnus-private' attribute of BBDB [1] works perfectly -- for years! --
> under (Windows) Emacs 24.5 (and many previous versions), it stops
> working when using Emacs 25.0.50 [2]... while (let's be explicit!) the
> `.gnus' file stays strictly the same.
Few! I was afraid that at this point you'd give us the actual error message!
Stefan
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Tue, 19 May 2015 17:59:01 GMT)
Full text and
rfc822 format available.
Message #11 received at 20610 <at> debbugs.gnu.org (full text, mbox):
Stefan Monnier <monnier <at> iro.umontreal.ca> writes:
>> While "fancy mail splitting" (section 6.4.6 of the manual) with the
>> `gnus-private' attribute of BBDB [1] works perfectly -- for years! --
>> under (Windows) Emacs 24.5 (and many previous versions), it stops
>> working when using Emacs 25.0.50 [2]... while (let's be explicit!) the
>> `.gnus' file stays strictly the same.
>
> Few! I was afraid that at this point you'd give us the actual error
> message!
I wish I could, but there isn't:
--8<---------------cut here---------------start------------->8---
...
nnimap read 10k from mail
Reading active file via nndraft...done
Checking new news...done
...
--8<---------------cut here---------------end--------------->8---
Not even a message about splitting.
The only visible difference is that, under 24.5, it does apply the
splitting rules, and it does not under 25.0.
Now, if there is a mean to get more verbose output, or something in the
same vein, I'm (of course) willing to try...
Best regards,
Seb
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Tue, 19 May 2015 18:41:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 20610 <at> debbugs.gnu.org (full text, mbox):
>> Few! I was afraid that at this point you'd give us the actual error
>> message!
> I wish I could, but there isn't:
> --8<---------------cut here---------------start------------->8---
> ...
> nnimap read 10k from mail
> Reading active file via nndraft...done
> Checking new news...done
> ...
> --8<---------------cut here---------------end--------------->8---
> Not even a message about splitting.
Well, that's already a lot more precise than just saying "stops
working", thanks.
> The only visible difference is that, under 24.5, it does apply the
> splitting rules, and it does not under 25.0.
I think we need some help from the Gnus guys here,
Stefan
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Wed, 20 May 2015 00:23:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 20610 <at> debbugs.gnu.org (full text, mbox):
On Tue, 19 May 2015 14:39:29 -0400, Stefan Monnier wrote:
> I think we need some help from the Gnus guys here,
After starting up Gnus, try this form in the *scratch* buffer:
(featurep 'bbdb-gnus) ;; Type `C-j' at the end of the form.
If this returns nil, it means your ~/.gnus file, containing
the splitting rules, is not loaded. If so, a possible cause is
that you have ~/.gnus.el or ~/.gnus.elc, that's accidentally made.
Gnus prefers those files than ~/.gnus [1]. Even if ~/.gnus.el
or ~/.gnus.elc is empty, Gnus would work just like normal
because of ~/.newsrc.eld.
[1] (info "(gnus)Startup Files")
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Thu, 21 May 2015 11:52:01 GMT)
Full text and
rfc822 format available.
Message #20 received at 20610 <at> debbugs.gnu.org (full text, mbox):
Katsumi Yamaoka <yamaoka <at> jpl.org> writes:
> On Tue, 19 May 2015 14:39:29 -0400, Stefan Monnier wrote:
>> I think we need some help from the Gnus guys here,
>
> After starting up Gnus, try this form in the *scratch* buffer:
>
> (featurep 'bbdb-gnus) ;; Type `C-j' at the end of the form.
>
> If this returns nil, it means your ~/.gnus file, containing
> the splitting rules, is not loaded.
It _is_ loaded; it returns `t'.
> If so, a possible cause is that you have ~/.gnus.el or ~/.gnus.elc,
> that's accidentally made. Gnus prefers those files than ~/.gnus.
> Even if ~/.gnus.el or ~/.gnus.elc is empty, Gnus would work just like
> normal because of ~/.newsrc.eld.
I know that, that's why I never ever compile my config files -- because
I've been hit quite a couple of times but that problem in the past, and
because the startup time of my Emacs/Gnus is already very decent now (in
the order of 1 to 3 seconds).
As I said, what's un-understandable right now, is that my config _works_
with Emacs 24.5 and (the exact same) does not with Emacs 25.
The problems you point to (possibly missing package or use of
a compiled, not up-to-date, config file) couldn't explain that fact.
Both versions of Emacs read my `~/.gnus' file and load the `bbdb-gnus'
library found at `~/.emacs.d/elpa/bbdb-20140830.2031/bbdb-gnus.elc'.
To add more data points, here is a comparison of what's displayed in the
`*Messages*' buffer for both sessions:
- With Emacs 24.5:
--8<---------------cut here---------------start------------->8---
Opening connection to mail via tls...
auth-source-search: found 1 results (max 1) matching (:max 1 :host ("mail") :port (993 "imaps" "imap" "993" "143") :user nil :require (:user :secret) :create t)
Opening connection to mail...done
Reading d:/Users/sva/.gnus.d/.newsrc.eld...
Checking new news...
Decrypting d:/Users/sva/.authinfo.gpg...done
auth-source-search: found 1 results (max 1) matching (:max 1 :host ("news.gmane.org" "gmane") :port ("119" "nntp" "nntp" "563" "nntps" "snews"))
auth-source-search: found 1 results (max 1) matching (:max 1 :host ("news.eternal-september.org" "eternal-september") :port ("119" "nntp" "nntp" "563" "nntps" "snews"))
> nnimap mail splitting mail...
nnimap read 0k from mail
> Parsing BBDB...
> Duplicate BBDB record encountered: Support
> Parsing BBDB...done
> nnimap mail splitting mail...done
> nnimap read 2k from mail
Reading active file via nndraft...done
Checking new news...done
--8<---------------cut here---------------end--------------->8---
- With Emacs 25.0:
--8<---------------cut here---------------start------------->8---
Opening connection to mail via tls...
auth-source-search: found 1 results (max 1) matching (:max 1 :host ("mail") :port (993 "imaps" "imap" "993" "143") :user nil :require (:user :secret) :create t)
Opening connection to mail...done
Reading d:/Users/sva/.gnus.d/.newsrc.eld...
Checking new news...
Decrypting d:/Users/sva/.authinfo.gpg...done
auth-source-search: found 1 results (max 1) matching (:max 1 :host ("news.gmane.org" "gmane") :port ("119" "nntp" "nntp" "563" "nntps" "snews"))
> Unable to open server nntp+gmane due to: Authorization Rejected
auth-source-search: found 1 results (max 1) matching (:max 1 :host ("news.eternal-september.org" "eternal-september") :port ("119" "nntp" "nntp" "563" "nntps" "snews"))
nnimap read 0k from mail
Reading active file via nndraft...done
Checking new news...done
--8<---------------cut here---------------end--------------->8---
Note that I've prefixed the lines which are different with a ">".
Best regards,
Seb
PS- I also have a problem with Gmane in Emacs 25.0, but I didn't look
into that yet.
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Fri, 22 May 2015 21:37:01 GMT)
Full text and
rfc822 format available.
Message #23 received at 20610 <at> debbugs.gnu.org (full text, mbox):
Sebastien Vauban <sva-news <at> mygooglest.com> writes:
> Katsumi Yamaoka <yamaoka <at> jpl.org> writes:
>> On Tue, 19 May 2015 14:39:29 -0400, Stefan Monnier wrote:
>>> I think we need some help from the Gnus guys here,
>>
>> (featurep 'bbdb-gnus) ;; Type `C-j' at the end of the form.
>
> It _is_ loaded; it returns `t'. [...] Both versions of Emacs read my
> `~/.gnus' file and load the `bbdb-gnus' library found at
> `~/.emacs.d/elpa/bbdb-20140830.2031/bbdb-gnus.elc'.
I'm progressing -- a bit. I just found out that, adding good ol'
messages, the conditional code is well executed (as already said)...
--8<---------------cut here---------------start------------->8---
(message ">>> >>> %S <<< <<<" nnimap-split-methods)
(when (require 'bbdb-gnus)
(message ">>> >>> Inside! <<< <<<")
;; Split function to use (sorting mails into groups using BBDB).
(setq nnimap-split-methods 'nnimap-split-fancy)
;; Specify how to split mail.
(setq nnimap-split-fancy ; vs `nnmail-split-fancy'?
'(| ; Split to the *first* match.
;; Invoke BBDB.
(: (lambda ()
(car (bbdb/gnus-split-method))))
;; Catch spam.
("X-Spam-Status" "[Yy]es"
"INBOX.Spam")
;; Undecided.
"INBOX"))
;; For records which don't have `gnus-private' set, the rules in
;; `split-fancy' are invoked.
(setq bbdb/gnus-split-default-group nil))
(message ">>> >>> %S <<< <<<" nnimap-split-methods)
--8<---------------cut here---------------end--------------->8---
gives:
--8<---------------cut here---------------start------------->8---
>>> >>> nil <<< <<<
>>> >>> Inside! <<< <<<
>>> >>> nnimap-split-fancy <<< <<<
--8<---------------cut here---------------end--------------->8---
... but, in Emacs 25.0, _after having started Gnus_, when I type `C-h
v nnimap-split-methods', I get `nil'!!! And similarly for
`nnimap-split-fancy'... So, these variables gets reinitialized after my
code is run... How? Why?
In Emacs 25, if I reevaluate the above 2 vars (`nnimap-split-methods'
and `nnimap-split-fancy'), the mail splitting is still not working,
though `B t' indicates it would go to the right mailbox! Why??
Another difference with Emacs 24.5: for these 3 messages to be evaluated
correctly, I had to explicitly add a `require 'nnimap' before the first
call to `message'. Otherwise, I had an "Error in ~/.gnus:
nnimap-split-methods"... Why is the variable not defined (I guess it
means that) in Emacs 24.5 and well in Emacs 25 -- without the explicit
call to nnimap?
Do the above ring a bell to someone?
I've seen that the nnimap vars are defined thru `defvoo' calls. I wasn't
aware of such a macro, and don't know yet its real effects...
Best regards,
Seb
--
Sebastien Vauban
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Fri, 24 Jul 2015 14:50:02 GMT)
Full text and
rfc822 format available.
Message #26 received at 20610 <at> debbugs.gnu.org (full text, mbox):
solved
close
Sebastien Vauban <sva-news <at> mygooglest.com> writes:
> Sebastien Vauban <sva-news <at> mygooglest.com> writes:
>> Sebastien Vauban <sva-news <at> mygooglest.com> writes:
>>> Katsumi Yamaoka <yamaoka <at> jpl.org> writes:
>>>> On Tue, 19 May 2015 14:39:29 -0400, Stefan Monnier wrote:
>>>>> I think we need some help from the Gnus guys here,
>>>>
>>>> (featurep 'bbdb-gnus) ;; Type `C-j' at the end of the form.
>>>
>>> It _is_ loaded; it returns `t'. [...] Both versions of Emacs read my
>>> `~/.gnus' file and load the `bbdb-gnus' library found at
>>> `~/.emacs.d/elpa/bbdb-20140830.2031/bbdb-gnus.elc'.
>>
>> I'm progressing -- a bit. I just found out that [...] in Emacs 25.0,
>> _after having started Gnus_, when I type `C-h v nnimap-split-methods',
>> I get `nil'!!! And similarly for `nnimap-split-fancy'... So, these
>> variables gets reinitialized after my code is run... How? Why?
>
> As I still need to read my mails within Emacs 25.0, and as the fancy
> mail splitting still does not work for me there (while it does, with
> the same config file, within Emacs 24.5), I have done more tests [...]
>
> ;; Configure incoming mail.
> (setq gnus-select-method
> '(nnimap "mail"
> (nnimap-address "mail")
> (nnimap-server-port 993)
> (nnimap-stream ssl)))
Putting *both* `nnimap-inbox' and `nnimap-split-methods' in the
definition of the IMAP select method is *necessary* for fancy splitting
to work under Emacs 25.
Working example:
--8<---------------cut here---------------start------------->8---
;; Configure incoming mail.
(setq gnus-select-method
'(nnimap "mail"
(nnimap-address "mail")
(nnimap-server-port 993)
(nnimap-stream ssl)
(nnimap-inbox "INBOX")
(nnimap-split-methods nnmail-split-fancy)))
--8<---------------cut here---------------end--------------->8---
Best regards,
Seb
bug closed, send any further explanations to
20610 <at> debbugs.gnu.org and Sebastien Vauban <sva-news <at> mygooglest.com>
Request was from
Glenn Morris <rgm <at> gnu.org>
to
control <at> debbugs.gnu.org
.
(Fri, 24 Jul 2015 15:53:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 22 Aug 2015 11:24:04 GMT)
Full text and
rfc822 format available.
bug unarchived.
Request was from
Gijs Hillenius <gijs <at> hillenius.net>
to
control <at> debbugs.gnu.org
.
(Fri, 14 Oct 2016 10:38:01 GMT)
Full text and
rfc822 format available.
Did not alter fixed versions and reopened.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Fri, 14 Oct 2016 10:39:01 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-gnu-emacs <at> gnu.org, bugs <at> gnus.org
:
bug#20610
; Package
emacs,gnus
.
(Mon, 17 Oct 2016 06:34:02 GMT)
Full text and
rfc822 format available.
Message #37 received at 20610 <at> debbugs.gnu.org (full text, mbox):
Trying out Debian's Emacs25, (GNU Emacs 25.1.1 (x86_64-pc-linux-gnu,
GTK+ Version 3.22.1) of 2016-10-11, modified by Debian)
I notice that my fancy split using bbdb is no longer working, similar to
what Sebastien Vauban noticed last year.
In the server buffer, this is how the mail server is configured
(nnimap "thuis"
(nnimap-address "server")
(nnimap-inbox "INBOX")
(nnimap-split-methods nnimap-split-fancy)
(nnimap-unsplittable-articles
'(%Deleted %Seen))
(nnir-search-engine imap)
(nnimap-stream tls))
Which works in Emacs24.
here is a shortened version of my nnimap-split-fancy
(setq nnimap-split-fancy
'(|
("from" "stuff.*" "INBOX.stuff")
("from" "no-reply <at> stuff" "INBOX.tmp")
;; Invoke the BBDB
(: (lambda ()
(car (bbdb/gnus-split-method))))
;; Default mailbox
"INBOX"))
The difference with Sebastian's fix from 24 Jul 2015 is that he uses
nnimap-split-methods nnmail-split-fancy, whereas in my case it is
nnimap-split-fancy.
In Emacs25, nnimap-split-methods is nil
In Emacs24, its value is nnimap-split-fancy
In Emacs25, when I reload Gnus, (r), nnimap-split-fancy gets the
intended value, and splitting works as before. So, somehow, m-x gnus
reads my .gnus file, and then forgets (some parts of) it.
Not sure what to do.. Not sure how to debug this either.
Would appreciate some pointers. Thanks
bug closed, send any further explanations to
20610 <at> debbugs.gnu.org and Sebastien Vauban <sva-news <at> mygooglest.com>
Request was from
Gijs Hillenius <gijs <at> hillenius.net>
to
control <at> debbugs.gnu.org
.
(Fri, 28 Oct 2016 07:59:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Fri, 25 Nov 2016 12:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 8 years and 290 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.