This is now the error I get using purelymail with SMTP working and the lock file deleted. Also, btw, if apache2 services are restarted, the lock file seems to be regenerated. not sure if that is intended or not.
PHP Warning: iconv(): Wrong encoding, conversion from "UTF7-IMAP" to "UTF-8//IGNORE" is not allowed in /var/www/domain/plugins/php-imap/vendor/symfony/polyfill-mbstring/Mbstring.php on line 116
Error: No inbox folder found.PHP Warning: Undefined variable $messages in /var/www/domain/cron_ticket_email_parser.php on line 355
PHP Fatal error: Uncaught Error: Call to a member function count() on null in /var/www/domain/cron_ticket_email_parser.php:355
Stack trace:
#0 {main}
thrown in /var/www/domain/cron_ticket_email_parser.php on line 355