Gnus development mailing list
 help / color / mirror / Atom feed
* Posting a draft to a newsgroup stopped(?) working?
@ 2021-01-01 19:42 Adam Sjøgren
  2021-01-01 20:38 ` Eric Abrahamsen
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-01 19:42 UTC (permalink / raw)
  To: ding

I think it used to work to start writing a new article in a newsgroup,
saving it as a draft, and then sending it later?

I can't make that work anymore - instead when I try to send the draft, I
first get a warning that the newsgroup might not exist (although it
does, I'm subscribed to it, it's in my *Group* buffer), and then the
article can't be posted, because Gnus tries to post it via my primary
method, which is (nnnil), and that is read-only.

*Messages* shows:

  Really use this possibly unknown group: gmane.emacs.gnus.general? (y or n) y
  Sending news via nnnil...
  Read-only server
  Couldn’t send message via news: Read-only server

Anyone else seeing this?

Is the Newsgroups: header in the draft-message supposed to be "fully
qualified"? (Because it isn't.)


  Best regards,

    Adam

-- 
 "I wear my unprofessionalism as a badge of honor.          Adam Sjøgren
  Professionalism has no place in art"                 asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 19:42 Posting a draft to a newsgroup stopped(?) working? Adam Sjøgren
@ 2021-01-01 20:38 ` Eric Abrahamsen
  2021-01-01 20:48   ` Mock Turtle
  0 siblings, 1 reply; 24+ messages in thread
From: Eric Abrahamsen @ 2021-01-01 20:38 UTC (permalink / raw)
  To: ding

Adam Sjøgren <asjo@koldfront.dk> writes:

> I think it used to work to start writing a new article in a newsgroup,
> saving it as a draft, and then sending it later?

Here goes my attempt, I'm starting a followup to this article, and now
saving to drafts.

Now I've gone to the drafts buffer, and starting editing my article
again, so far everything looks normal.

> I can't make that work anymore - instead when I try to send the draft, I
> first get a warning that the newsgroup might not exist (although it
> does, I'm subscribed to it, it's in my *Group* buffer), and then the
> article can't be posted, because Gnus tries to post it via my primary
> method, which is (nnnil), and that is read-only.
>
> *Messages* shows:
>
>   Really use this possibly unknown group: gmane.emacs.gnus.general? (y or n) y
>   Sending news via nnnil...
>   Read-only server
>   Couldn’t send message via news: Read-only server
>
> Anyone else seeing this?
>
> Is the Newsgroups: header in the draft-message supposed to be "fully
> qualified"? (Because it isn't.)

In my case the Newsgroups header is not fully qualified, but my nntp
server is also my primary method, so I expect it will work fine. Here
goes.



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 20:38 ` Eric Abrahamsen
@ 2021-01-01 20:48   ` Mock Turtle
  2021-01-01 20:53     ` Eric Abrahamsen
  0 siblings, 1 reply; 24+ messages in thread
From: Mock Turtle @ 2021-01-01 20:48 UTC (permalink / raw)
  To: ding

Mock Turtle <eric@ericabrahamsen.net> writes:

> Adam Sjøgren <asjo@koldfront.dk> writes:
>
>> I think it used to work to start writing a new article in a newsgroup,
>> saving it as a draft, and then sending it later?
>
> Here goes my attempt, I'm starting a followup to this article, and now
> saving to drafts.
>
> Now I've gone to the drafts buffer, and starting editing my article
> again, so far everything looks normal.

Now I start a Gnus mock session where nntp is a secondary server, start
a followup to this article, and save the draft.

Now start editing the draft -- the Newsgroups header is now unqualified,
and we expect that will give us trouble. Here goes.



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 20:48   ` Mock Turtle
@ 2021-01-01 20:53     ` Eric Abrahamsen
  2021-01-01 21:02       ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Eric Abrahamsen @ 2021-01-01 20:53 UTC (permalink / raw)
  To: ding

Mock Turtle <eric@ericabrahamsen.net> writes:

> Mock Turtle <eric@ericabrahamsen.net> writes:
>
>> Adam Sjøgren <asjo@koldfront.dk> writes:
>>
>>> I think it used to work to start writing a new article in a newsgroup,
>>> saving it as a draft, and then sending it later?
>>
>> Here goes my attempt, I'm starting a followup to this article, and now
>> saving to drafts.
>>
>> Now I've gone to the drafts buffer, and starting editing my article
>> again, so far everything looks normal.
>
> Now I start a Gnus mock session where nntp is a secondary server, start
> a followup to this article, and save the draft.
>
> Now start editing the draft -- the Newsgroups header is now unqualified,
> and we expect that will give us trouble. Here goes.

Bad news for you! Looks like it works okay here.



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 20:53     ` Eric Abrahamsen
@ 2021-01-01 21:02       ` Adam Sjøgren
  2021-01-01 21:17         ` Mock Turtle
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-01 21:02 UTC (permalink / raw)
  To: ding

Eric writes:

> Bad news for you! Looks like it works okay here.

Thanks for testing - I wonder what I have messed up in my
configuration...

Could you do a test where you quit Gnus and Emacs after saving the
draft, and then start a new Emacs, Gnus and post? Just to be 100% sure.


  Best regards,

    Adam

-- 
 "Lägg ditt liv i min hand                                  Adam Sjøgren
  Sälj din själ till ett band"                         asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 21:02       ` Adam Sjøgren
@ 2021-01-01 21:17         ` Mock Turtle
  2021-01-01 21:23           ` Eric Abrahamsen
  0 siblings, 1 reply; 24+ messages in thread
From: Mock Turtle @ 2021-01-01 21:17 UTC (permalink / raw)
  To: ding

Adam Sjøgren <asjo@koldfront.dk> writes:

> Eric writes:
>
>> Bad news for you! Looks like it works okay here.
>
> Thanks for testing - I wonder what I have messed up in my
> configuration...
>
> Could you do a test where you quit Gnus and Emacs after saving the
> draft, and then start a new Emacs, Gnus and post? Just to be 100% sure.

Here's the draft, saving...

Stopped and restarted Emacs, now sending.



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 21:17         ` Mock Turtle
@ 2021-01-01 21:23           ` Eric Abrahamsen
  2021-01-01 21:44             ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Eric Abrahamsen @ 2021-01-01 21:23 UTC (permalink / raw)
  To: ding

Mock Turtle <eric@ericabrahamsen.net> writes:

> Adam Sjøgren <asjo@koldfront.dk> writes:
>
>> Eric writes:
>>
>>> Bad news for you! Looks like it works okay here.
>>
>> Thanks for testing - I wonder what I have messed up in my
>> configuration...
>>
>> Could you do a test where you quit Gnus and Emacs after saving the
>> draft, and then start a new Emacs, Gnus and post? Just to be 100% sure.
>
> Here's the draft, saving...
>
> Stopped and restarted Emacs, now sending.

*Messages* clearly said "sending with news.gmane.io via nntp" or
whatever, so it wasn't confused. I suppose one other thing would be to
try with `gnus-select-method' set to nnnil, in case that causes some
particular hiccup.



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 21:23           ` Eric Abrahamsen
@ 2021-01-01 21:44             ` Adam Sjøgren
  2021-01-02  0:18               ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-01 21:44 UTC (permalink / raw)
  To: ding

Eric writes:

>> Here's the draft, saving...
>>
>> Stopped and restarted Emacs, now sending.
>
> *Messages* clearly said "sending with news.gmane.io via nntp" or
> whatever, so it wasn't confused. I suppose one other thing would be to
> try with `gnus-select-method' set to nnnil, in case that causes some
> particular hiccup.

Thanks for testing - I think this used to work for me, so maybe I've
messed something up in my configuration recently (I've been using
(nnnil) as primary method for ages)...


  Best regards,

    Adam

-- 
 "They were trying to make me an insider to some            Adam Sjøgren
  kind of trip they were on. I don't think so."        asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-01 21:44             ` Adam Sjøgren
@ 2021-01-02  0:18               ` Adam Sjøgren
  2021-01-02  0:58                 ` Eric Abrahamsen
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  0:18 UTC (permalink / raw)
  To: ding

Found it!

For some reason the draft in question had a X-Draft-From: header line
with the value ("nndrafts:drafts") instead of the (nntp-server:group N)
I otherwise see.

I'm not sure how that happened. Perhaps by editing a draft and saving
it? Got to test some more...

Ah! A new article (a) in a group doesn't result in an X-Draft-From:
header, which means the draft can't be posted, as the method is (nnnil).

But if it is a follow up, the draft has a X-Draft-From: which Gnus then
seems to use to figure out what server to use for posting.

So it only happens on drafts that are not follow ups.


  Best regards,

    Adam

-- 
 "Civility and politeness are extremely useful tools        Adam Sjøgren
  in communication with people who are more wrong      asjo@koldfront.dk
  than right, but of very little use with people who
  are vastly more right than wrong."



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  0:18               ` Adam Sjøgren
@ 2021-01-02  0:58                 ` Eric Abrahamsen
  2021-01-02  1:02                   ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Eric Abrahamsen @ 2021-01-02  0:58 UTC (permalink / raw)
  To: ding

Adam Sjøgren <asjo@koldfront.dk> writes:

> Found it!
>
> For some reason the draft in question had a X-Draft-From: header line
> with the value ("nndrafts:drafts") instead of the (nntp-server:group N)
> I otherwise see.
>
> I'm not sure how that happened. Perhaps by editing a draft and saving
> it? Got to test some more...
>
> Ah! A new article (a) in a group doesn't result in an X-Draft-From:
> header, which means the draft can't be posted, as the method is (nnnil).
>
> But if it is a follow up, the draft has a X-Draft-From: which Gnus then
> seems to use to figure out what server to use for posting.
>
> So it only happens on drafts that are not follow ups.

Okay, I just tried that and it worked, but again I did that from my
usual setup which has nntp as `gnus-select-method'. I did observe the
same as you, that if the draft is not a followup it doesn't get an
X-Draft-From header. Just that, in my case, that was apparently okay.



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  0:58                 ` Eric Abrahamsen
@ 2021-01-02  1:02                   ` Adam Sjøgren
  2021-01-02  2:03                     ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  1:02 UTC (permalink / raw)
  To: ding

Eric writes:

>> So it only happens on drafts that are not follow ups.
>
> Okay, I just tried that and it worked, but again I did that from my
> usual setup which has nntp as `gnus-select-method'. I did observe the
> same as you, that if the draft is not a followup it doesn't get an
> X-Draft-From header. Just that, in my case, that was apparently okay.

Yeah, I wonder if there isn't some code that finds the correct
nntp-server if the primary one isn't matching, like a fallback, which
doesn't kick in when nnnil is the primary method.

I have managed to find a random year old commit where it worked, so I am
currently bisecting...


  Best regards,

    Adam

-- 
 "Sunday morning when the rain begins to fall               Adam Sjøgren
  I've got the cure for it all"                        asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  1:02                   ` Adam Sjøgren
@ 2021-01-02  2:03                     ` Adam Sjøgren
  2021-01-02  2:14                       ` Andrew Cohen
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  2:03 UTC (permalink / raw)
  To: ding

Adam writes:

> I have managed to find a random year old commit where it worked, so I am
> currently bisecting...

Okay, I have bisected it down to the commit that changed the behaviour
to _not_ add a X-Draft-From: header to new drafts (that are not follow
ups).

Unfortunately it's a big one:

  ecfc13e41627511769e00a2d0a7568d5bdbe8a0d is the first bad commit
  commit ecfc13e41627511769e00a2d0a7568d5bdbe8a0d
  Author: Andrew G Cohen <cohen@andy.bu.edu>
  Date:   Sat Sep 5 08:46:43 2020 +0800

      Introduce nnselect backend for gnus

 - https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=ecfc13e41627511769e00a2d0a7568d5bdbe8a0d


  Best regards,

    Adam

-- 
 '"Evig Pint" blir som ventet ikke noen hyllevarmer.'       Adam Sjøgren
                                                       asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  2:03                     ` Adam Sjøgren
@ 2021-01-02  2:14                       ` Andrew Cohen
  2021-01-02  2:25                         ` Adam Sjøgren
  2021-01-02  2:37                         ` Adam Sjøgren
  0 siblings, 2 replies; 24+ messages in thread
From: Andrew Cohen @ 2021-01-02  2:14 UTC (permalink / raw)
  To: ding


Interesting. This is probably an error (I don't think this should have
done anything to this header). I will look into it, but do you have more
info about exactly what in this patch caused the change?



-- 



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  2:14                       ` Andrew Cohen
@ 2021-01-02  2:25                         ` Adam Sjøgren
  2021-01-02  2:37                         ` Adam Sjøgren
  1 sibling, 0 replies; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  2:25 UTC (permalink / raw)
  To: ding

Andrew writes:

> Interesting. This is probably an error (I don't think this should have
> done anything to this header). I will look into it, but do you have more
> info about exactly what in this patch caused the change?

Unfortunately not, there are a lot of changes in the commit - I would
have loved to be able to bisect it further!

Skimming over the commit, nothing jumps in my eyes (not that that says
much! :-))

It is easy to reproduce, however:

 a) Go to an nntp-group (e.g. gmane.test)

 b) Create a new article (a), don't send it, but save it (C-x C-s)
    (creates an article in nndraft:drafts)

 c) Look at the new draft's headers (t). Before the patch:
    'X-Draft-From: ("nntp+gm:gmane.test")' is there. After: it isn't.


  Best regards,

    Adam

-- 
 "Vad lär vi oss af denna lilla sketchen?"                  Adam Sjøgren
 "Ja, det kan man ängstligt undra."                    asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  2:14                       ` Andrew Cohen
  2021-01-02  2:25                         ` Adam Sjøgren
@ 2021-01-02  2:37                         ` Adam Sjøgren
  2021-01-02  3:33                           ` Adam Sjøgren
  1 sibling, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  2:37 UTC (permalink / raw)
  To: ding

Andrew writes:

> Interesting. This is probably an error (I don't think this should have
> done anything to this header). I will look into it, but do you have more
> info about exactly what in this patch caused the change?

How do you debug a defmacro?

I'm guessing it is due some of the changes to gnus-setup-message in
gnus-msg.el (I can't find anywhere else where the header is added), but
my usual basic trick of M-x edebug-defun is failing me for stepping
through and trying to figure out what is going on :-)


  Best regards,

    Adam

-- 
 "Tom has put all my music into this rectangle."            Adam Sjøgren
                                                       asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  2:37                         ` Adam Sjøgren
@ 2021-01-02  3:33                           ` Adam Sjøgren
  2021-01-02  3:40                             ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  3:33 UTC (permalink / raw)
  To: ding

Adam writes:

> Andrew writes:
>
>> Interesting. This is probably an error (I don't think this should have
>> done anything to this header). I will look into it, but do you have more
>> info about exactly what in this patch caused the change?
>
> How do you debug a defmacro?
>
> I'm guessing it is due some of the changes to gnus-setup-message in
> gnus-msg.el (I can't find anywhere else where the header is added), but
> my usual basic trick of M-x edebug-defun is failing me for stepping
> through and trying to figure out what is going on :-)

Ok, so I have printf/(message) debugged a little bit. I'm looking at
this part of gnus-setup-message in gnus-msg.el:

       (gnus-alist-pull ',(intern gnus-draft-meta-information-header)
		  message-required-headers)
       (message "ASJO group %s" ,group)
       (when (and ,group
		  (not (string= ,group "")))
	 (push (cons
		(intern gnus-draft-meta-information-header)
		(gnus-inews-make-draft (or ,yanked ,article)))
	       message-required-headers))
       (message "ASJO message-requires-headers %s" message-required-headers)
       (unwind-protect

If I go to an nntp-group and do a to create a new article, the output
is:

  ASJO group nil
  ASJO message-requires-headers ((optional . References) From)

If I instead go f to create a follow up, the output is:

  ASJO group nntp+gm:gmane.test
  ASJO message-requires-headers ((X-Draft-From lambda nil (gnus-inews-make-draft-meta-information nntp+gm:gmane.test '8744)) (optional . References) From)

So I guess group used to be filled in regardless, but now it isn't?!


  Best regards,

    Adam

-- 
 "I skal gå tre skridt væk fra mig                          Adam Sjøgren
  For jeg har fundet en som rammer"                    asjo@koldfront.dk



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  3:33                           ` Adam Sjøgren
@ 2021-01-02  3:40                             ` Adam Sjøgren
  2021-01-02  3:45                               ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  3:40 UTC (permalink / raw)
  To: ding

Adam writes:

> If I go to an nntp-group and do a to create a new article, the output
> is:
>
>   ASJO group nil

> So I guess group used to be filled in regardless, but now it isn't?!

Looking at how ,group in the diff:

  -        (,group (if (and (gnus-nnir-group-p gnus-newsgroup-name)
  -                         gnus-article-reply)
  -                    (nnir-article-group (or (car-safe gnus-article-reply)
  -                                            gnus-article-reply))
  -                  gnus-newsgroup-name))
  +        (,group (when gnus-article-reply
  +                  (or (nnselect-article-group
  +                       (or (car-safe gnus-article-reply)
  +                           gnus-article-reply))
  +                      gnus-newsgroup-name)))

Before the change ,group would be set to gnus-newsgroup-name if
gnus-article-reply was false, but after the change, it doesn't get set
if g-a-reply is false, right?

Is that change in logic intended?


  Best regards,

    Adam

-- 
 "I’ve been so fortunate riding waves and being born        Adam Sjøgren
  at a time that was just right for my particular      asjo@koldfront.dk
  peculiarity."



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  3:40                             ` Adam Sjøgren
@ 2021-01-02  3:45                               ` Adam Sjøgren
  2021-01-02  3:52                                 ` Andrew Cohen
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  3:45 UTC (permalink / raw)
  To: ding

Adam writes:

>> So I guess group used to be filled in regardless, but now it isn't?!

>   +        (,group (when gnus-article-reply
>   +                  (or (nnselect-article-group
>   +                       (or (car-safe gnus-article-reply)
>   +                           gnus-article-reply))
>   +                      gnus-newsgroup-name)))

If I change it to this:

	   (,group (if gnus-article-reply
		     (or (nnselect-article-group
			  (or (car-safe gnus-article-reply)
			      gnus-article-reply))
			 gnus-newsgroup-name)
                     gnus-newsgroup-name))

it works for new articles, i.e. X-Draft-From: gets set. It looks a
little clumsy, but it was the easiest thing to try.


  Best regards,

    Adam

-- 
 "It's like somebody with obsessive-compulsive              Adam Sjøgren
  disorder constantly rearranging the names to fit     asjo@koldfront.dk
  into some sort of perfect ontology they have in
  their heads."



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  3:45                               ` Adam Sjøgren
@ 2021-01-02  3:52                                 ` Andrew Cohen
  2021-01-02  4:01                                   ` Adam Sjøgren
  2021-01-02  4:02                                   ` Andrew Cohen
  0 siblings, 2 replies; 24+ messages in thread
From: Andrew Cohen @ 2021-01-02  3:52 UTC (permalink / raw)
  To: ding


>>>>> "AS" == Adam Sjøgren <asjo@koldfront.dk> writes:

    AS> Adam writes:
    >>> So I guess group used to be filled in regardless, but now it
    >>> isn't?!

    >> + (,group (when gnus-article-reply + (or (nnselect-article-group
    >> + (or (car-safe gnus-article-reply) + gnus-article-reply)) +
    >> gnus-newsgroup-name)))

    AS> If I change it to this:

    AS> 	   (,group (if gnus-article-reply (or
    AS> (nnselect-article-group (or (car-safe gnus-article-reply)
    AS> gnus-article-reply)) gnus-newsgroup-name) gnus-newsgroup-name))

I made this change probably 4 years ago, so I don't remember the
details. The trick is to make sure that the right group is used when
coming from an nnselect group, but I recall there were several
subtleties involved and some corner cases that the previous code got
wrong. I think that the logic of your correction is right (should have
been an if rather than a when), but the easiest way to tell is to make
the change and see if anything else stops working. 

-- 



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  3:52                                 ` Andrew Cohen
@ 2021-01-02  4:01                                   ` Adam Sjøgren
  2021-01-02  4:02                                   ` Andrew Cohen
  1 sibling, 0 replies; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  4:01 UTC (permalink / raw)
  To: ding

Andrew writes:

> I made this change probably 4 years ago,

I guess it's an argument for "release often and early", but that's easy
for me to say afterwards!

> The trick is to make sure that the right group is used when coming
> from an nnselect group, but I recall there were several subtleties
> involved and some corner cases that the previous code got wrong.

I can imagine... when I try to change something it feels... daunting.

> I think that the logic of your correction is right (should have been
> an if rather than a when), but the easiest way to tell is to make the
> change and see if anything else stops working.

I'm using it right now, so far, so good!

(I'm not a huge user of nnselect yet, though, so that's not saying that
much.)

Thanks for looking (back) into this.


  Best regards,

    Adam

-- 
 "It is time to take out the trash, and we need to          Adam Sjøgren
  stop supporting pay basis distros such as communist  asjo@koldfront.dk
  Redhat. They are charging us for the stuff thats
  spose to be free."



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  3:52                                 ` Andrew Cohen
  2021-01-02  4:01                                   ` Adam Sjøgren
@ 2021-01-02  4:02                                   ` Andrew Cohen
  2021-01-02  4:10                                     ` Adam Sjøgren
  1 sibling, 1 reply; 24+ messages in thread
From: Andrew Cohen @ 2021-01-02  4:02 UTC (permalink / raw)
  To: ding


Actually, can you try the following patch (I think there is a
corresponding error in setting the article number)? Just run with it for
awhile and lets see if anything else goes wrong (seems to be ok in my 5
minutes of testing :))

diff --git a/lisp/gnus/gnus-msg.el b/lisp/gnus/gnus-msg.el
index 465871eafb..faae0a882d 100644
--- a/lisp/gnus/gnus-msg.el
+++ b/lisp/gnus/gnus-msg.el
@@ -409,18 +409,18 @@ gnus-setup-message
     `(let ((,winconf (current-window-configuration))
           (,winconf-name gnus-current-window-configuration)
           (,buffer (buffer-name (current-buffer)))
-          (,article   (when gnus-article-reply
+          (,article   (if gnus-article-reply
                         (or (nnselect-article-number
                              (or (car-safe gnus-article-reply)
-                                 gnus-article-reply))
-                            gnus-article-reply)))
+                                 gnus-article-reply)))
+                            gnus-article-reply))
           (,oarticle gnus-article-reply)
           (,yanked gnus-article-yanked-articles)
-          (,group (when gnus-article-reply
+          (,group (if gnus-article-reply
                     (or (nnselect-article-group
                          (or (car-safe gnus-article-reply)
-                             gnus-article-reply))
-                        gnus-newsgroup-name)))
+                             gnus-article-reply)))
+                        gnus-newsgroup-name))
           (message-header-setup-hook
            (copy-sequence message-header-setup-hook))
           (mbl mml-buffer-list)



-- 



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  4:02                                   ` Andrew Cohen
@ 2021-01-02  4:10                                     ` Adam Sjøgren
  2021-01-02  4:32                                       ` Andrew Cohen
  0 siblings, 1 reply; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  4:10 UTC (permalink / raw)
  To: ding

Andrew writes:

> Actually, can you try the following patch (I think there is a
> corresponding error in setting the article number)?

I don't think there'll be an article number for the draft of a new
article?

Only for a follow up (the number of the article the follow up is on).

> -          (,article   (when gnus-article-reply
> +          (,article   (if gnus-article-reply
>                          (or (nnselect-article-number
>                               (or (car-safe gnus-article-reply)
> -                                 gnus-article-reply))
> -                            gnus-article-reply)))
> +                                 gnus-article-reply)))
> +                            gnus-article-reply))

You now have an "if gnus-article-reply", which when false returns
gnus-article-reply. Looks like a change that doesn't do much?


  Best regards,

    Adam

-- 
 "Ride the tail of rhyme                                    Adam Sjøgren
  Break the legs of time                               asjo@koldfront.dk
  Snap its spine"



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  4:10                                     ` Adam Sjøgren
@ 2021-01-02  4:32                                       ` Andrew Cohen
  2021-01-02  4:42                                         ` Adam Sjøgren
  0 siblings, 1 reply; 24+ messages in thread
From: Andrew Cohen @ 2021-01-02  4:32 UTC (permalink / raw)
  To: ding

>>>>> "AS" == Adam Sjøgren <asjo@koldfront.dk> writes:

    AS> Andrew writes:
    >> Actually, can you try the following patch (I think there is a
    >> corresponding error in setting the article number)?

    AS> I don't think there'll be an article number for the draft of a
    AS> new article?


Right, I didn't look closely. I think what happened  is that 4 years ago
I changed the ,article clause  and without looking too closely thought
the newsgroup clause was the same.  So pretty sure that you found the
fix and it shouldn't impact anything else. I'll push this to master
soon.

Best,
Andy



-- 



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

* Re: Posting a draft to a newsgroup stopped(?) working?
  2021-01-02  4:32                                       ` Andrew Cohen
@ 2021-01-02  4:42                                         ` Adam Sjøgren
  0 siblings, 0 replies; 24+ messages in thread
From: Adam Sjøgren @ 2021-01-02  4:42 UTC (permalink / raw)
  To: ding

Andrew writes:

> I think what happened is that 4 years ago I changed the ,article
> clause and without looking too closely thought the newsgroup clause
> was the same.

Ah, yes, sounds plausible.

> So pretty sure that you found the fix and it shouldn't impact anything
> else. I'll push this to master soon.

👍 thanks!


  Best regards,

    Adam

-- 
 "And made you captain? They are giving the title           Adam Sjøgren
  away now."                                           asjo@koldfront.dk



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

end of thread, other threads:[~2021-01-02  4:42 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-01 19:42 Posting a draft to a newsgroup stopped(?) working? Adam Sjøgren
2021-01-01 20:38 ` Eric Abrahamsen
2021-01-01 20:48   ` Mock Turtle
2021-01-01 20:53     ` Eric Abrahamsen
2021-01-01 21:02       ` Adam Sjøgren
2021-01-01 21:17         ` Mock Turtle
2021-01-01 21:23           ` Eric Abrahamsen
2021-01-01 21:44             ` Adam Sjøgren
2021-01-02  0:18               ` Adam Sjøgren
2021-01-02  0:58                 ` Eric Abrahamsen
2021-01-02  1:02                   ` Adam Sjøgren
2021-01-02  2:03                     ` Adam Sjøgren
2021-01-02  2:14                       ` Andrew Cohen
2021-01-02  2:25                         ` Adam Sjøgren
2021-01-02  2:37                         ` Adam Sjøgren
2021-01-02  3:33                           ` Adam Sjøgren
2021-01-02  3:40                             ` Adam Sjøgren
2021-01-02  3:45                               ` Adam Sjøgren
2021-01-02  3:52                                 ` Andrew Cohen
2021-01-02  4:01                                   ` Adam Sjøgren
2021-01-02  4:02                                   ` Andrew Cohen
2021-01-02  4:10                                     ` Adam Sjøgren
2021-01-02  4:32                                       ` Andrew Cohen
2021-01-02  4:42                                         ` Adam Sjøgren

Gnus development mailing list

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://inbox.vuxu.org/ding

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 ding ding/ http://inbox.vuxu.org/ding \
		ding@inbox.vuxu.org
	public-inbox-index ding

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.vuxu.org/vuxu.archive.emacs.gnus.general


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git