Gnus development mailing list
 help / color / mirror / Atom feed
* nnimap splitting weirdness
@ 2014-03-06  3:30 Eric Abrahamsen
  2014-03-06  3:46 ` Malcolm Purvis
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Eric Abrahamsen @ 2014-03-06  3:30 UTC (permalink / raw)
  To: ding

A month or so ago, all my nnimap splitting stopped working: everything
suddenly was getting sent to the default "mail.misc" group. I only just
got around to looking into what happened.

Turns out that nnimap-split-fancy is getting set to "nil" somehow, so
splitting falls back on the default value of nnmail-split-fancy -->
"mail.misc". That's pretty weird, because nnimap-split-fancy is set in
my .gnus.el file, same as always. It was definitely nil, though, and
manually re-evaluating the form where it's set made everything work
normally again.

What's weirder is that, a little later on, it was "nil" again. It's hard
to know when the value got cleared, but I had to go and manually
re-evaluate it again. I'm poking into it more right now.

Given the timing of the problem (I keep up with git head on a weekly
basis or so), and looking through the git log, I'm guessing it might be
cfa942d that is responsible, not that I have any real idea what's
happening in that commit. At least it looks like it's capable of
resetting this value!

Any hints on what might be going on? I'm using git gnus and GNU Emacs
24.3.1.

Thanks!
Eric




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06  3:30 nnimap splitting weirdness Eric Abrahamsen
@ 2014-03-06  3:46 ` Malcolm Purvis
  2014-03-08  8:59   ` Eric Abrahamsen
  2014-03-06 18:06 ` Andreas Schwab
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 11+ messages in thread
From: Malcolm Purvis @ 2014-03-06  3:46 UTC (permalink / raw)
  To: ding

>>>>> "Eric" == Eric Abrahamsen <eric@ericabrahamsen.net> writes:

Eric> Turns out that nnimap-split-fancy is getting set to "nil" somehow,
Eric> so splitting falls back on the default value of nnmail-split-fancy
Eric> --> "mail.misc".

I'm not sure that the cause it, but I worked around it by initialising
nnimap-split-fancy and friends as select method parameters rather than
as globals.

Malcolm

-- 
		     Malcolm Purvis <malcolmp@xemacs.org>



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06  3:30 nnimap splitting weirdness Eric Abrahamsen
  2014-03-06  3:46 ` Malcolm Purvis
@ 2014-03-06 18:06 ` Andreas Schwab
  2014-03-08  8:56   ` Eric Abrahamsen
  2014-03-07 17:04 ` Lars Ingebrigtsen
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 11+ messages in thread
From: Andreas Schwab @ 2014-03-06 18:06 UTC (permalink / raw)
  To: Eric Abrahamsen; +Cc: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> Any hints on what might be going on? I'm using git gnus and GNU Emacs
> 24.3.1.

Perhaps you could add a hack to Fset to watch for assignments to
nnimap-split-fancy and trigger a backtrace.

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06  3:30 nnimap splitting weirdness Eric Abrahamsen
  2014-03-06  3:46 ` Malcolm Purvis
  2014-03-06 18:06 ` Andreas Schwab
@ 2014-03-07 17:04 ` Lars Ingebrigtsen
  2014-03-10  6:18 ` Eric Abrahamsen
  2014-03-20  4:54 ` Eric Abrahamsen
  4 siblings, 0 replies; 11+ messages in thread
From: Lars Ingebrigtsen @ 2014-03-07 17:04 UTC (permalink / raw)
  To: Eric Abrahamsen; +Cc: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> Turns out that nnimap-split-fancy is getting set to "nil" somehow, so
> splitting falls back on the default value of nnmail-split-fancy -->
> "mail.misc". That's pretty weird, because nnimap-split-fancy is set in
> my .gnus.el file, same as always. It was definitely nil, though, and
> manually re-evaluating the form where it's set made everything work
> normally again.
>
> What's weirder is that, a little later on, it was "nil" again. It's hard
> to know when the value got cleared, but I had to go and manually
> re-evaluate it again. I'm poking into it more right now.

Have you tried just grepping through everything?  >"?

$ grep nnmail-spilt-fancy `find ~ -type f`

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



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06 18:06 ` Andreas Schwab
@ 2014-03-08  8:56   ` Eric Abrahamsen
  2014-03-08 10:13     ` Eric Abrahamsen
  0 siblings, 1 reply; 11+ messages in thread
From: Eric Abrahamsen @ 2014-03-08  8:56 UTC (permalink / raw)
  To: ding

Andreas Schwab <schwab@linux-m68k.org> writes:

> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
>> Any hints on what might be going on? I'm using git gnus and GNU Emacs
>> 24.3.1.
>
> Perhaps you could add a hack to Fset to watch for assignments to
> nnimap-split-fancy and trigger a backtrace.
>
> Andreas.

This seemed like an interesting idea, but I haven't quite been able to
get it to work. `fset' doesn't seem right, that's only for defining
functions. Is that what you meant? I tried to advise `set', because I'd
always thought all variable assignment eventually made use of set, but
nothing happened when I tested a setq form with nnimap-split-fancy.
Advising `setq' directly resulted in "Lisp nesting exceeds
`max-lisp-eval-depth'", perhaps just because I'm doing the advice wrong:


(defadvice setq (before hands-off-nnimap-splitting
		       (&rest args))
  "Try to figure out who's setting nnimap-split-fancy back to nil."
  (message "args: %s" args)
  ad-do-it
)

(ad-activate 'setq)

Anyone have any pointers here?

Also, on the subject of the original problem, I see there's both these:

gnus-sum.el:(defvar nnimap-split-fancy)
nnimap.el:(defvoo nnimap-split-fancy nil

I don't suppose it matters that there are two definitions for the same
variable? I don't know enough about variable assignment to know if this
is normal.

Thanks,
Eric




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06  3:46 ` Malcolm Purvis
@ 2014-03-08  8:59   ` Eric Abrahamsen
  2014-03-08 11:26     ` Malcolm Purvis
  0 siblings, 1 reply; 11+ messages in thread
From: Eric Abrahamsen @ 2014-03-08  8:59 UTC (permalink / raw)
  To: ding

Malcolm Purvis <malcolmp@xemacs.org> writes:

>>>>>> "Eric" == Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
> Eric> Turns out that nnimap-split-fancy is getting set to "nil" somehow,
> Eric> so splitting falls back on the default value of nnmail-split-fancy
> Eric> --> "mail.misc".
>
> I'm not sure that the cause it, but I worked around it by initialising
> nnimap-split-fancy and friends as select method parameters rather than
> as globals.

I do set the select method parameters with (nnimap-split-methods
nnimap-split-fancy) in each method definition, but I also set a global
value for nnimap-split-fancy in .gnus.el, so that each server uses the
same definition. I wonder if that could be why it's going wrong...




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-08  8:56   ` Eric Abrahamsen
@ 2014-03-08 10:13     ` Eric Abrahamsen
  0 siblings, 0 replies; 11+ messages in thread
From: Eric Abrahamsen @ 2014-03-08 10:13 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> Andreas Schwab <schwab@linux-m68k.org> writes:
>
>> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>>
>>> Any hints on what might be going on? I'm using git gnus and GNU Emacs
>>> 24.3.1.
>>
>> Perhaps you could add a hack to Fset to watch for assignments to
>> nnimap-split-fancy and trigger a backtrace.
>>
>> Andreas.
>
> This seemed like an interesting idea, but I haven't quite been able to
> get it to work. `fset' doesn't seem right, that's only for defining
> functions. Is that what you meant? I tried to advise `set', because I'd
> always thought all variable assignment eventually made use of set, but
> nothing happened when I tested a setq form with nnimap-split-fancy.
> Advising `setq' directly resulted in "Lisp nesting exceeds
> `max-lisp-eval-depth'", perhaps just because I'm doing the advice wrong:

Ignore this, I'm obviously Doing It Wrong, will read the manual...




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-08  8:59   ` Eric Abrahamsen
@ 2014-03-08 11:26     ` Malcolm Purvis
  0 siblings, 0 replies; 11+ messages in thread
From: Malcolm Purvis @ 2014-03-08 11:26 UTC (permalink / raw)
  To: ding

>>>>> "Eric" == Eric Abrahamsen <eric@ericabrahamsen.net> writes:

Eric> I do set the select method parameters with (nnimap-split-methods
Eric> nnimap-split-fancy) in each method definition, but I also set a
Eric> global value for nnimap-split-fancy in .gnus.el, so that each
Eric> server uses the same definition. I wonder if that could be why
Eric> it's going wrong...

I had the same setup but had to change it to be something like:

(setq gnus-select-method
   `(nnimap "home"
       (nnimap-split-fancy ,mp-nnimap-split-fancy)
       (nnimap-inbox "INBOX")
       (nnimap-split-methods nnmail-split-fancy)))

Where mp-nnimap-split-fancy is set globally.

When were the use of the global forms disabled?

Malcolm

-- 
		     Malcolm Purvis <malcolmp@xemacs.org>



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06  3:30 nnimap splitting weirdness Eric Abrahamsen
                   ` (2 preceding siblings ...)
  2014-03-07 17:04 ` Lars Ingebrigtsen
@ 2014-03-10  6:18 ` Eric Abrahamsen
  2014-03-10 12:29   ` Malcolm Purvis
  2014-03-20  4:54 ` Eric Abrahamsen
  4 siblings, 1 reply; 11+ messages in thread
From: Eric Abrahamsen @ 2014-03-10  6:18 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> A month or so ago, all my nnimap splitting stopped working: everything
> suddenly was getting sent to the default "mail.misc" group. I only just
> got around to looking into what happened.

Gah, I still can't figure this out. Whatever changed changed in late
January, and I went through the git logs, reverting a couple of commits
and testing, and I can't find anything that seems to be responsible.

I wasn't able to advise setq to see what was re-setting
nnimap-split-fancy, because defadvice itself uses setqs, and that
created loops.

I tried using Malcolm's back-quote suggestion, but that doesn't seem to
work either. In my gnus.el I changed things to look like:

(require 'bbdb-gnus)
(setq my-nnimap-split-fancy `(|
			   ,@(bbdb/gnus-nnimap-folder-list-from-bbdb)
                           ; other splits
			   (: gnus-group-split-fancy nil t nil)
			   "INBOX"))

(setq gnus-secondary-select-methods
      `(
	(nnimap "one" 
		(nnimap-inbox "INBOX")
		(nnimap-split-methods nnmail-split-fancy)
		(nnimap-split-methods ,my-nnimap-split-fancy))
	(nnimap "two"
		(nnimap-inbox "INBOX")
		(nnimap-split-methods nnmail-split-fancy)
		(nnimap-split-methods ,my-nnimap-split-fancy))
	; more similar accounts
))

When I start gnus, first of all it hangs. I hit C-g to get out of the
hang and it starts up as normal. But still, nothing splits correctly,
everything still goes to the nnmail-split-fancy default of "mail.misc".

I don't know what to do!

E




^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-10  6:18 ` Eric Abrahamsen
@ 2014-03-10 12:29   ` Malcolm Purvis
  0 siblings, 0 replies; 11+ messages in thread
From: Malcolm Purvis @ 2014-03-10 12:29 UTC (permalink / raw)
  To: ding

>>>>> "Eric" == Eric Abrahamsen <eric@ericabrahamsen.net> writes:

Eric> (setq gnus-secondary-select-methods
Eric>       `(
Eric> 	(nnimap "one"
Eric> 		(nnimap-inbox "INBOX")
Eric>           (nnimap-split-methods nnmail-split-fancy)
Eric>           (nnimap-split-methods ,my-nnimap-split-fancy))
Eric> ))

Eric,

Your second nnimap-split-methods entry should instead be a reference to
nnimap-split-fancy:

(setq gnus-secondary-select-methods
      `(
	(nnimap "one"
		(nnimap-inbox "INBOX")
          (nnimap-split-methods nnmail-split-fancy)
          (nnimap-split-fancy ,my-nnimap-split-fancy))
))

Malcolm

-- 
		     Malcolm Purvis <malcolmp@xemacs.org>



^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: nnimap splitting weirdness
  2014-03-06  3:30 nnimap splitting weirdness Eric Abrahamsen
                   ` (3 preceding siblings ...)
  2014-03-10  6:18 ` Eric Abrahamsen
@ 2014-03-20  4:54 ` Eric Abrahamsen
  4 siblings, 0 replies; 11+ messages in thread
From: Eric Abrahamsen @ 2014-03-20  4:54 UTC (permalink / raw)
  To: ding

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> A month or so ago, all my nnimap splitting stopped working: everything
> suddenly was getting sent to the default "mail.misc" group. I only just
> got around to looking into what happened.

Okay I finally went and git bisected this (I did it twice, as I'd never
done this before), and both times came up with this commit as the
beginning of the troubles.

5a0a6cc1fef60642ac30c3e24e06b8a45c994612
Author: Lars Ingebrigtsen <larsi@gnus.org>                                 
Date:   Tue Feb 4 19:16:31 2014 -0800                                      
    Download the Cloud chunks                                              
                                                                           
    * nnimap.el (nnimap-request-articles): New command to download several 
    articles at once.                                                          

In this patch we get gnus-cloud-download-data, and
nnimap-request-articles. I can't at first glance tell why this would
result in nnimap-split-fancy getting clobbered, but I can look into it.

I'd really rather fix this than need backquoting tricks in my
.gnus.el....

Eric




^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-03-20  4:54 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-06  3:30 nnimap splitting weirdness Eric Abrahamsen
2014-03-06  3:46 ` Malcolm Purvis
2014-03-08  8:59   ` Eric Abrahamsen
2014-03-08 11:26     ` Malcolm Purvis
2014-03-06 18:06 ` Andreas Schwab
2014-03-08  8:56   ` Eric Abrahamsen
2014-03-08 10:13     ` Eric Abrahamsen
2014-03-07 17:04 ` Lars Ingebrigtsen
2014-03-10  6:18 ` Eric Abrahamsen
2014-03-10 12:29   ` Malcolm Purvis
2014-03-20  4:54 ` Eric Abrahamsen

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 NNTP newsgroup(s).