I have a script put together that parses attachments out of emails and uploads them to a database. Recently, some emails that came through were not processed properly. Since the script runs unattended and my logging is not the best (is on my list of todos to fix), I want to re-process one of the problemed emails via running the script manually. Simple enough?
Well, at first, fetchmail would not retrieve the message at all since it had already "seen" it previously. I figured out that adding --fetchall would force fetchmail to re-download the message. However, even though fetchmail seems to go through the motions of retrieving the aforementioned message, it is not in the mail spool.
If I send new (unique) messages to the account the script watches, fetchmail downloads the message without issue and I see it in the mail spool.
There must be something I'm missing between fetch mail and the user's mail spool, but I'm not sure where to go next.
Any ideas?