Gnus development mailing list
 help / color / mirror / Atom feed
* gnus-delay problem
@ 2003-02-03 10:40 Kai Großjohann
  2003-02-04  5:43 ` Katsumi Yamaoka
  0 siblings, 1 reply; 7+ messages in thread
From: Kai Großjohann @ 2003-02-03 10:40 UTC (permalink / raw)


gnus-delay-article invokes nndraft-request-create-group to create the
nndraft:delayed group.  But after invoking the command, I have a file
~/News/drafts/delayed but `U' and `j' and gnus-newsrc-hashtb and
gnus-active-hashtb do not know the group.

What did I do wrong (in gnus-delay.el)?  I think it used to work?
-- 
A turnip curses Elvis



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

* Re: gnus-delay problem
  2003-02-03 10:40 gnus-delay problem Kai Großjohann
@ 2003-02-04  5:43 ` Katsumi Yamaoka
  0 siblings, 0 replies; 7+ messages in thread
From: Katsumi Yamaoka @ 2003-02-04  5:43 UTC (permalink / raw)


>>>>> In <848ywxhckc.fsf@lucy.is.informatik.uni-duisburg.de>
>>>>>	kai.grossjohann@uni-duisburg.de (Kai Großjohann) wrote:

> gnus-delay-article invokes nndraft-request-create-group to create the
> nndraft:delayed group.  But after invoking the command, I have a file
> ~/News/drafts/delayed but `U' and `j' and gnus-newsrc-hashtb and
> gnus-active-hashtb do not know the group.

> What did I do wrong (in gnus-delay.el)?  I think it used to work?

That's a mystery for me too.  I needed to use `G m' to create
the nndraft:delayed group if my vague memory doesn't deceive me.
-- 
Katsumi Yamaoka <yamaoka@jpl.org>



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

* Re: gnus-delay problem
  2003-04-29 17:56   ` Jesper Harder
@ 2003-04-30 14:53     ` Kai Großjohann
  0 siblings, 0 replies; 7+ messages in thread
From: Kai Großjohann @ 2003-04-30 14:53 UTC (permalink / raw)


Jesper Harder <harder@myrealbox.com> writes:

> Yup, it works fine.  Thanks.

Cool.  Will commit.
-- 
file-error; Data: (Opening input file no such file or directory ~/.signature)



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

* Re: gnus-delay problem
  2003-04-29 15:26 ` Kai Großjohann
@ 2003-04-29 17:56   ` Jesper Harder
  2003-04-30 14:53     ` Kai Großjohann
  0 siblings, 1 reply; 7+ messages in thread
From: Jesper Harder @ 2003-04-29 17:56 UTC (permalink / raw)


kai.grossjohann@gmx.net (Kai Großjohann) writes:

> Jesper Harder <harder@myrealbox.com> writes:
>
>> I can't get gnus-delay working.  
>
> I've now snarfed code from the agent to do this.  Here is a patch.
> But I haven't tested it.  Does it work?

Yup, it works fine.  Thanks.



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

* Re: gnus-delay problem
  2003-04-28 22:52 Jesper Harder
  2003-04-29 15:17 ` Kai Großjohann
@ 2003-04-29 15:26 ` Kai Großjohann
  2003-04-29 17:56   ` Jesper Harder
  1 sibling, 1 reply; 7+ messages in thread
From: Kai Großjohann @ 2003-04-29 15:26 UTC (permalink / raw)


Jesper Harder <harder@myrealbox.com> writes:

> I can't get gnus-delay working.  
>
> The problem appears to be the code in `gnus-delay-article' which is
> responsible for creating the delay group:
>
>   ;; If group does not exist, create it.
>   (let ((group (format "nndraft:%s" gnus-delay-group)))
>     (unless (gnus-gethash group gnus-newsrc-hashtb)
>       (nndraft-request-create-group gnus-delay-group)
>       ;; Make it active.
>       (gnus-set-active group (cons 1 0))))

I've now snarfed code from the agent to do this.  Here is a patch.
But I haven't tested it.  Does it work?

I still don't understand any of it.

cvs server: Diffing .
cvs server: Diffing contrib
cvs server: Diffing etc
cvs server: Diffing etc/gnus
cvs server: Diffing etc/smilies
cvs server: Diffing lisp
Index: lisp/gnus-agent.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-agent.el,v
retrieving revision 6.168
diff -u -r6.168 gnus-agent.el
--- lisp/gnus-agent.el	27 Apr 2003 04:30:29 -0000	6.168
+++ lisp/gnus-agent.el	29 Apr 2003 15:34:52 -0000
@@ -608,14 +608,18 @@
 		       gnus-agent-covered-methods ))))
      (append (list gnus-select-method) gnus-secondary-select-methods))))
 
-(defun gnus-agent-queue-setup ()
-  "Make sure the queue group exists."
-  (unless (gnus-gethash "nndraft:queue" gnus-newsrc-hashtb)
-    (gnus-request-create-group "queue" '(nndraft ""))
+(defun gnus-agent-queue-setup (&optional group-name)
+  "Make sure the queue group exists.
+Optional arg GROUP-NAME allows to specify another group."
+  (unless (gnus-gethash (format "nndraft:%s" (or group-name "queue"))
+			gnus-newsrc-hashtb)
+    (gnus-request-create-group (or group-name "queue") '(nndraft ""))
     (let ((gnus-level-default-subscribed 1))
-      (gnus-subscribe-group "nndraft:queue" nil '(nndraft "")))
+      (gnus-subscribe-group (format "nndraft:%s" (or group-name "queue"))
+			    nil '(nndraft "")))
     (gnus-group-set-parameter
-     "nndraft:queue" 'gnus-dummy '((gnus-draft-mode)))))
+     (format "nndraft:%s" (or group-name "queue"))
+     'gnus-dummy '((gnus-draft-mode)))))
 
 (defun gnus-agent-send-mail ()
   (if gnus-plugged
Index: lisp/gnus-delay.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-delay.el,v
retrieving revision 6.20
diff -u -r6.20 gnus-delay.el
--- lisp/gnus-delay.el	8 Feb 2003 21:20:53 -0000	6.20
+++ lisp/gnus-delay.el	29 Apr 2003 15:34:52 -0000
@@ -134,10 +134,7 @@
   (set-buffer-modified-p t)
   ;; If group does not exist, create it.
   (let ((group (format "nndraft:%s" gnus-delay-group)))
-    (unless (gnus-gethash group gnus-newsrc-hashtb)
-      (nndraft-request-create-group gnus-delay-group)
-      ;; Make it active.
-      (gnus-set-active group (cons 1 0))))
+    (gnus-agent-queue-setup gnus-delay-group))
   (message-disassociate-draft)
   (nndraft-request-associate-buffer gnus-delay-group)
   (save-buffer 0)
cvs server: Diffing texi
cvs server: Diffing texi/etc
cvs server: Diffing texi/herds
cvs server: Diffing texi/misc
cvs server: Diffing texi/picons
cvs server: Diffing texi/ps
cvs server: Diffing texi/screen
cvs server: Diffing texi/smilies
cvs server: Diffing texi/xface


-- 
file-error; Data: (Opening input file no such file or directory ~/.signature)



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

* Re: gnus-delay problem
  2003-04-28 22:52 Jesper Harder
@ 2003-04-29 15:17 ` Kai Großjohann
  2003-04-29 15:26 ` Kai Großjohann
  1 sibling, 0 replies; 7+ messages in thread
From: Kai Großjohann @ 2003-04-29 15:17 UTC (permalink / raw)


Jesper Harder <harder@myrealbox.com> writes:

> The problem appears to be the code in `gnus-delay-article' which is
> responsible for creating the delay group:
>
>   ;; If group does not exist, create it.
>   (let ((group (format "nndraft:%s" gnus-delay-group)))
>     (unless (gnus-gethash group gnus-newsrc-hashtb)
>       (nndraft-request-create-group gnus-delay-group)
>       ;; Make it active.
>       (gnus-set-active group (cons 1 0))))
>
> The directory for the delay group is created, but Gnus doesn't find
> the group and it isn't entered in my `gnus-newsrc-hashtb'.  After
> executing the above
>
>     (gnus-gethash group gnus-newsrc-hashtb)
>
> still returns nil.

I think I snarfed this code from the spot where nndraft:drafts is
created.  So if that code has changed, the gnus-delay code may have
to be changed, too.

I know it was a stupid thing to do to copy and paste things that I
didn't understand.
-- 
file-error; Data: (Opening input file no such file or directory ~/.signature)



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

* gnus-delay problem
@ 2003-04-28 22:52 Jesper Harder
  2003-04-29 15:17 ` Kai Großjohann
  2003-04-29 15:26 ` Kai Großjohann
  0 siblings, 2 replies; 7+ messages in thread
From: Jesper Harder @ 2003-04-28 22:52 UTC (permalink / raw)


I can't get gnus-delay working.  

The problem appears to be the code in `gnus-delay-article' which is
responsible for creating the delay group:

  ;; If group does not exist, create it.
  (let ((group (format "nndraft:%s" gnus-delay-group)))
    (unless (gnus-gethash group gnus-newsrc-hashtb)
      (nndraft-request-create-group gnus-delay-group)
      ;; Make it active.
      (gnus-set-active group (cons 1 0))))

The directory for the delay group is created, but Gnus doesn't find
the group and it isn't entered in my `gnus-newsrc-hashtb'.  After
executing the above

    (gnus-gethash group gnus-newsrc-hashtb)

still returns nil.

What could be the problem?



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

end of thread, other threads:[~2003-04-30 14:53 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-02-03 10:40 gnus-delay problem Kai Großjohann
2003-02-04  5:43 ` Katsumi Yamaoka
2003-04-28 22:52 Jesper Harder
2003-04-29 15:17 ` Kai Großjohann
2003-04-29 15:26 ` Kai Großjohann
2003-04-29 17:56   ` Jesper Harder
2003-04-30 14:53     ` Kai Großjohann

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).