nicm / fdm

fdm source code
268 stars 50 forks source link

Message-ID header mandated for all mails? #99

Closed x3nb63 closed 2 years ago

x3nb63 commented 2 years ago

my fd.conf has this:

$id = "%[message_id]%[date]"

...

match not string $id to "" {
    ... more matching ...
}

The %[date] I put into the id because some mails don't get fetched and I figured they do not contain a Message-ID: ... header line, but all have a Date: ... - so I would fall back on this for the matching id.

That done ... and these mails still don't get fetched.

Then in fdm fetch -vvv I discover a line <account>: message-id is: ... for each processed message. But I get no hint on the ones not being fetched!

So my question is whether fdm is outright oblivious to those?

nicm commented 2 years ago

message-id is not required.

x3nb63 commented 2 years ago

hmm, then I am out of ideas why its not fetching these mails.

are there some IMAP numbers with which to relate which is what? ... looking for ~5 out of 700 ...

nicm commented 2 years ago

If you run with enough -v (maybe 3 or 4?) you will get the raw server traffic as well then you can see exactly what it is getting from the server. Are you sure the mails aren't marked as seen already?

x3nb63 commented 2 years ago

fdm -vvvv fetch revealed that %[date] does not exist; had to use %[mail_rfc822date] to get some index value for the mails in question.... then improper encoding made my further matching not match ....

Thanks!

another question rises:

can fdm toggle the read/unread mark on IMAP? decided by a match?

right now I fetch all mails in the box cause I can not rely on new-only since the server may or may not perform another processing step on the mailbox - so I must inspect the mail body before knowing that I want it ... would be way more efficient to only do that for new ones and leave them new until the server is done ...

(I'll close this ticket anyway cause its another topic)