Page 2 of 3

Re: Cron error periodically

Posted: Thu Jan 30, 2020 3:52 am
by hesker
Just got it again, slightly over an hour after the previous one.

Re: Cron error periodically

Posted: Thu Jan 30, 2020 6:51 am
by Klemen
Both POP3 and IMAP use the same code to parse received email so no matter how they are received they all get processed (passed to) the same functions.

Please turn Debug mode ON in Hesk admin panel > Settings > Help desk tab > look under Features and we'll see if we get a better error message.

Re: Cron error periodically

Posted: Sun Feb 09, 2020 7:24 pm
by hesker
Finally had a chance to look into this, but debug mode revealed nothing:
Connected to the IMAP server "{domain.com:993/imap/ssl/novalidate-cert}".
No unread messages found.
Disconnected from the IMAP server.
Now what?

Re: Cron error periodically

Posted: Mon Feb 10, 2020 10:15 am
by Klemen
That's a normal response. I'd keep the debug mode active and see what it says when an error occurs.

Re: Cron error periodically

Posted: Wed Feb 12, 2020 7:57 pm
by hesker
As far as I can tell this IS the debug error. This is what I keep being sent, multiple times per day every day now. If I disable debug mode, I just get "An error occurred". If I enable debug, I get a seemingly normal response. I'm at a loss.

Re: Cron error periodically

Posted: Wed Feb 12, 2020 8:16 pm
by Klemen
Yeh, that's how Cron works - anything returned by the script will be emailed to you.

Unfortunately, there's no way around it - you need to keep debug mode active and receive an email every time the Cron job runs. When a connection error does occur, the error message should be different (and hopefully help us find the issue)?

Re: Cron error periodically

Posted: Thu Feb 13, 2020 3:34 pm
by hesker
i'll leave it running a few more days but so far, nothing but "correct" responses with debug enabled.

Re: Cron error periodically

Posted: Fri Feb 14, 2020 4:40 pm
by hesker
Still nothing but normal responses with debug enabled. I have no reason to think that's going to change.

Re: Cron error periodically

Posted: Fri Feb 14, 2020 8:55 pm
by hesker
I'm reasonably sure this error messages is a false positive. I only get it if debug is disabled, and there is no actual problem as the fetching works perfectly fine (both pop and imap).

Re: Cron error periodically

Posted: Sat Feb 15, 2020 7:48 am
by Klemen
Rather than a false one, it's probably a temporary one. On the next run, the mail server connection works fine so emails get fetched.

Re: Cron error periodically

Posted: Sat Feb 15, 2020 7:54 pm
by hesker
But then why, when debug is enabled, do I never get any errors, not even once?

Re: Cron error periodically

Posted: Sun Feb 16, 2020 6:48 am
by Klemen
Murphy :roll: ?

Nothing changes in the debug mode except that steps Hesk performs and PHP error messages are output, instead of silenced.

Re: Cron error periodically

Posted: Sun Feb 16, 2020 4:26 pm
by hesker
Yeah that's what I mean by some sort of false positive. Something, maybe specific to this host (SiteGround), is triggering the error messages frequently but not on every run, only when debug is disabled. But since I have no idea what to point them to, they just point to the script and say "talk to the author".

Re: Cron error periodically

Posted: Mon Feb 17, 2020 4:14 pm
by hesker
Now that debug is turned off again, I got the error once more.

<h2>An error occured.</h2><p>For details turn <b>Debug mode</b> ON in settings and run this script again.</p>

Re: Cron error periodically

Posted: Mon Feb 17, 2020 4:53 pm
by hesker
Wow I actually got a different error for once...

<pre>Can not authenticate to IMAP server: [CLOSED] IMAP connection broken (authenticate)</pre>