I'm trying to have a background task for handling emails, as suggested by the web2py Doc
Specifically, I have a python script named mail.py
that goes like this:
import time
from gluon.tools import Mail
mail = Mail()
mail.settings = ....
while True:
.....
SEND EMAILS
....
time.sleep(3600)
And I run it, as suggested by the docs, from the console as
python web2py.py -S APPLICATION_NAME -M -R applications/.../private/mail.py
The problem is that the console seems to die after a while. When I come back to the dashboard after a day or too, the console is empty. Is this a problem with pythonAnywhere or web2py?