It seemed to glitch out last night, but I admit I changed DeleteAfter from "false" to "true" in the meantime and that might have an effect.
I did notice that there was an easy way for me to tell in the imap2script-errors.log if it was working or not - if the last line was
2021/02/17 18:51:07 [INFO ] (id=0) Processing 0 unread message(s)
then it works. If that line isn't there, it seems to get stuck.
This is a log of a successful execution:
2021/02/17 18:51:07 [INFO ] (id=0) Got an IDLE mailbox update
2021/02/17 18:51:07 [INFO ] (id=0) Processing 1 unread message(s)
2021/02/17 18:51:07 [INFO ] (id=0) Processed 1 message(s)
2021/02/17 18:51:07 [INFO ] (id=0) Got an IDLE mailbox update
2021/02/17 18:51:07 [DEBUG] (id=0, i=0) Sending to script /home/worf/run_procmail
2021/02/17 18:51:07 [INFO ] (id=0, i=0) Script Script produced stderr:
procmail: [203432] Wed Feb 17 18:51:07 2021
procmail: Assigning "LOGFILE=/home/worf/procmail.log"
procmail: Opening "/home/worf/procmail.log"
2021/02/17 18:51:07 [INFO ] (id=0) Processing 0 unread message(s)
The only difference when it gets stuck is the last line goes missing
I'm going to try more controlled experiments to see if I can narrow down the issue.