mu icon indicating copy to clipboard operation
mu copied to clipboard

[mu4e bug] "replied" flag is not set after sending a reply

Open vladmaraev opened this issue 1 year ago • 6 comments

Describe the bug

I don't quite understand the mechanics of setting "replied" flag and In-Reply-To field, but I don't see In-Reply-To field while composing a message (I think I could see it in previous versions of mu4e). After sending, the incoming message doesn't get flagged with "replied" flag.

When examining raw contents of incoming messages I see that: For incoming message Message-ID: AS8P251MB02623BAA6AD3F7419E1A9ED1CB8F2@AS8P251MB0262.EURP251.PROD.OUTLOOK.COM For my reply: In-Reply-To: AS8P251MB02623BAA6AD3F7419E1A9ED1CB8F2@AS8P251MB0262.EURP251.PROD.OUTLOOK.COM (REDACTED's message of "Thu, 22 Aug 2024 15:08:39 +0000")

In the thread view these messages look as they should.

How to Reproduce

It happens each time I reply (mu4e-compose-wide-reply).

Environment

  • GNU Emacs 29.4 (build 1, aarch64-apple-darwin23.5.0, NS appkit-2487.60 Version 14.5 (Build 23F79))
  • mu4e - mu for emacs version 1.12.6

Checklist

  • I am running 1.12.x release
  • I can reproduce it in "emacs -Q"

vladmaraev avatar Aug 23 '24 10:08 vladmaraev

The In-Reply-To field is hidden by default; unhide it through the "Field" menu or by changing mu4e-draft-hidden-headers.

djcb avatar Aug 23 '24 16:08 djcb

Thanks for you reply. I didn't realise this. But now when I see it it is empty.

vladmaraev avatar Aug 23 '24 17:08 vladmaraev

Sorry I was mistaken. Now I can see it. But still, I don't get the 'replied' flag after the reply gets sent. I will try my best to further debug it myself.

vladmaraev avatar Aug 24 '24 11:08 vladmaraev

Just to mention that the issue is still present, even though In-Reply-To matches parent Message-ID.

vladmaraev avatar Aug 29 '24 18:08 vladmaraev

Setting the flags of the "parent" message when replying/forwarding is handled in mu4e--set-parent-flags. Are you able to see if it is called after you reply?

And can you find the "parent" message, with something like:

mu find msgid:AS8P251MB02623BAA6AD3F7419E1A9ED1CB8F2@AS8P251MB0262.EURP251.PROD.OUTLOOK.COM

djcb avatar Oct 20 '24 14:10 djcb

Yes, I can find it. I tried with a more recent reply, and can find the message referred to from "In-Reply-To" field.

vladmaraev avatar Oct 22 '24 09:10 vladmaraev

Perhaps a simple tests (this requires 1.12.8 for the logging).

  1. send yourself a test message
  2. wait until you receive it
  3. turn on mu4e-logging
  4. reply to your test message, send it, now in the log you should see something like:
2025-01-29 12:14:43.055 -> (add :path "/home/example/Maildir/sent/cur/1738145676.d73b29b5474b695a.abcd:2,S")
2025-01-29 12:14:43.155 mark [email protected] as Replied
2025-01-29 12:14:43.155 -> (move :docid nil :msgid "[email protected]" :flags "+R-N" :maildir nil :rename nil :no-view nil)
2025-01-29 12:14:43.155 -> (remove :path "/home/example/Maildir/drafts/cur/1738145676.0e5301a366d00669.abcd:2,DS")

and now the message you sent in (1) should get the "R" flag.

Do you see something similar?

djcb avatar Jan 29 '25 10:01 djcb

This has gotten stale... closing for now. Feel free to reopen with the requested information -- thanks!

djcb avatar Feb 25 '25 15:02 djcb

Sorry, I rolled back to 1.10.9 so I was inactive. But now I decided to try 1.12.9 again and managed to test it. Here is the log, it seems to be looking quite different.

2025-04-08 10:43:43.914 -> (add :path "/Users/xmarvl/Maildir/gu/Drafts/cur/1744101819.37cba42d25887669.ml-220216-001:2,DS")
2025-04-08 10:43:45.513 -> (remove :path "/Users/xmarvl/Maildir/gu/Drafts/cur/1744101819.37cba42d25887669.ml-220216-001:2,DS")
2025-04-08 10:43:45.540 * Received 684 byte(s)
2025-04-08 10:43:45.540 <- (:info add :path /Users/xmarvl/Maildir/gu/Drafts/cur/1744101819.37cba42d25887669.ml-220216-001:2,DS :docid 93995)
2025-04-08 10:43:45.540 <- (:update (:path /Users/xmarvl/Maildir/gu/Drafts/cur/1744101819.37cba42d25887669.ml-220216-001:2,DS :size 403 :changed (26612 57791 0) :date (26612 57791 0) :from ((:email [email protected] :name Vladislav Maraev)) :language en :message-id 05e14f0241d6c2698b87a8ccd7b16623c1e9c6260a9510e428432d025f9b3045@mu.id :priority normal :references ([email protected]) :subject Re: test :to ((:email [email protected] :name Vladislav Maraev)) :maildir /gu/Drafts :flags (draft seen personal) :docid 93995))
2025-04-08 10:43:45.540 <- (:remove 0)

vladmaraev avatar Apr 08 '25 08:04 vladmaraev

@djcb Would it be possible to reopen the issue?

vladmaraev avatar Apr 11 '25 11:04 vladmaraev

Hmm, the logs seems to show saving a draft message, did you follow the steps?

djcb avatar Apr 11 '25 16:04 djcb

2025-04-14 10:18:26.848 logging enabled
2025-04-14 10:18:38.981 -> (add :path "/Users/xmarvl/Maildir/gu/Drafts/cur/1744618716.226e924f255df6a2.ml-220216-001:2,DS")
2025-04-14 10:18:40.797 -> (remove :path "/Users/xmarvl/Maildir/gu/Drafts/cur/1744618716.226e924f255df6a2.ml-220216-001:2,DS")
2025-04-14 10:18:40.810 * Received 684 byte(s)
2025-04-14 10:18:40.810 <- (:info add :path /Users/xmarvl/Maildir/gu/Drafts/cur/1744618716.226e924f255df6a2.ml-220216-001:2,DS :docid 94440)
2025-04-14 10:18:40.810 <- (:update (:path /Users/xmarvl/Maildir/gu/Drafts/cur/1744618716.226e924f255df6a2.ml-220216-001:2,DS :size 613 :changed (26620 50398 0) :date (26620 50398 0) :from ((:email REDACTED :name Vladislav Maraev)) :language en :message-id a044b35d79cb131285e5ca6ecb744fe0d73a71bac6de619bdd329ed23c16212a@mu.id :priority normal :references ([email protected]) :subject Re: test :to ((:email REDACTED :name Vladislav Maraev)) :maildir /gu/Drafts :flags (draft seen personal) :docid 94440))
2025-04-14 10:18:40.810 <- (:remove 0)

Yes, this is what I get (I tried once again). I forgot to mention that I am using msmpt as sendmail-program, not sure if it matters.

vladmaraev avatar Apr 14 '25 08:04 vladmaraev

Seems your messages never make it to the sent-folder, i.e. mu4e-sent-folder, or?

Can you check if your draft messages include an "Fcc:" header? Note that you might need to check the raw file on the file-system.

djcb avatar Apr 14 '25 09:04 djcb