info-gnus-english
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Why expiry of drafts?


From: Adrian Lanz
Subject: Re: Why expiry of drafts?
Date: Tue, 27 Apr 2004 12:41:07 +0200
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (usg-unix-v)

On 26 Apr 2004, kai@emptydomain.de wrote:

> Adrian Lanz <lanz@fowi.ethz.ch> writes:
>
>> The funny thing is (besides that I do not see why a draft - in the
>> intermediate draft state - is expired at all!), that the expiry
>> target is correctly evaluated from my nnmail-fancy-expiry-targets
>> variable (in the example above it resolves to "wsl-2004"), but that
>> the destination "/home/lanz/mail/gnus" seems to be derived from
>> some "general value" of nnml-directory. Usually my mail messages
>> are expired to the nnml-directory "/home/lanz/mail/gnus/expired/"
>> as configured in variable gnus-secondary-select-methods. The
>> relevant parts of my configuration are:
>
> You didn't say what's your expiry-target configuration ;-)

Thanks for answering my questions. It is

  (setq gnus-total-expirable-newsgroups "nnfolder\\+mail:.*")
  (setq nnmail-expiry-target 'nnmail-fancy-expiry-target)
  (setq nnmail-fancy-expiry-targets 
        '(("xref" "spam\\.mail:[01-9]" "nnml+expired:spam.%Y")
          (to-from "ethz\\.ch" "nnml+expired:ethz-%Y")
          (to-from "wsl\\.ch" "nnml+expired:wsl-%Y")
          (to-from ".*" "nnml+expired:other-%Y")
          )))

> >
> I'm not sure if it is possible to specify fully qualified group
> names in nnmail-fancy-expiry-targets.  (Looks.)  It seems to be
> possible.  But there is no obvious place to put server-specific
> configuration.

For mail messages kept in "nnfolder\\+mail:.*", total expiry respects
the fully qualified group names in nnmail-fancy-expiry-targets.

>From a user's perspective, there is the logic to specify select
methods (backend end + server name) through variable
gnus-secondary-select-methods, and there should be - for the expiry
thing configureable through variables nnmail-expiry-target,
gnus-*-expirable-newsgroups and nnmail-expiry-wait-function - an
additional logic to specify the "expiry flow" from one (or several)
select methods to one (or several) other select methods. In this
contect, flow configuration should accept fully qualified group names.

This brings me to mind: A similar generalized mechanism should also be
available for incoming mail. Here we specify the mail-sources and the
flow from sources to select methods through nnmail-split-methods. What
happens, when there are several select methods with *-get-new-mail set
to t? I never tried. The logic - from a user's point of view - should
be to specify this flow (from mail sources to select methods) in
variable nnmail-split-methods. Thus, in a ideal Gnus world,
nnmail-split-methods would accept fully qualified group names to split
incoming mail from one (or many) mail sources to one (or many) select
methods.

> Hm.  Is it possible to add nnmail-fancy-expiry-targets as a server
> parameter?  Does anyone know?
>
>> (setq gnus-home-directory "/home/lanz/mail/gnus/")
>> (setq gnus-directory gnus-home-directory)
>> (setq message-directory gnus-home-directory)
>> (setq message-auto-save-directory (concat message-directory "drafts"))
>> (setq gnus-secondary-select-methods
>>      '(
>>        (nnfolder "mail"
>>                  ...
>>                  (nnfolder-get-new-mail t)
>>                  (nnfolder-inhibit-expiry nil))
>>        (nnml "expired"
>>              (nnml-directory "/home/lanz/mail/gnus/expired/")
>>              ...
>>              (nnfolder-get-new-mail nil)
>>              (nnfolder-inhibit-expiry t))))
>> (setq nnmail-expiry-wait-function
>>      (lambda (group)
>>        (cond ((string= group "spam.mail")
>>               5)
>>              (t
>>               30))))
>> (setq gnus-total-expirable-newsgroups "nnfolder\\+mail:.*")
>>
>> So if ever expiring of messages happens, it should be only in
>> "nnfolder\\+mail:.*" groups (definitively not in the
>> "nndraft:drafts" group), after 5 (spam) or 30 days (not immediately
>> as it seems to be the case for drafts) and into a subdirectory of
>> "/home/lanz/mail/gnus/expired/" (not "/home/lanz/mail/gnus/" as for
>> drafts).
>
> No, no, no.  Total-expire means that Gnus considers read articles
> (marks r, R, K, Y and so on) to be expirable, in addition to the
> articles explicitly marked as expirable (mark E).
>
> If you mark a message as expirable, using the E key (not e), then it
> will be expirable in any group.  You can set nnchoke-inhibit-expiry,
> and you can tweak expiry-wait, but you didn't do any of those for
> nndraft:drafts.

I am not understanding you here. For me, there are two problems which
are not necessarily (but may be) related. Why is Gnus expiring my
drafts immediately after sending the finished article (this should not
happen), and why does Gnus send the expired drafts to a place I would
not expect it to send it to?

1) What is the reason, that drafts get expired with my settings? (BTW,
   I think it is expiry, may be it just seems to be expiry? See the
   details in my first mail.) Does this happen for you? How do you
   specify mail that should get total (or auto) expired and its
   targets. Do I use some special configuration?  The documentation of
   variable gnus-total-expirable-newsgroups says:

   *Groups in which to perform expiry of all read articles. Use with
   extreme caution.  All groups that match this regexp will be
   expiring - which means that all read articles will be deleted after
   (say) one week.  (This only goes for mail groups and the like, of
   course.)

   With (setq gnus-total-expirable-newsgroups "nnfolder\\+mail:.*"), I
   conclude, that expiry should never happen in nndrafts.

2) I keep incoming mail in nnfolder+mail: and expired articles in
   nnml+expired:, both backends being configured in variable
   gnus-secondary-select-methods. No problems with that. But an
   article expired from the draft group (which BTW should never
   happen, see point 1 above), does not respect the nnmail+expired:
   settings, but "invents" a new expiry server, which seems to be a
   nnml: server (which is not configured and does not appear in the
   server buffer) in a default directory. Why is Gnus not using the
   nnml+expired: server, i.e. respecting the nnml-directory (and other
   server variables) configured in the gnus-secondary-select-methods
   variable? And also, why are the drafts expired immediately?

Thanks, Adrian.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]