How to Enable Automatic Email Sending in ERPNext?

Can anyone assist?

Whenever I send an email through the ERPNext application, it does not automatically send the mail. Instead, it goes to the ‘Email NOT SENT’ status. I have to manually go to the email queue list, select the particular email, and click the ‘Send Now’ button to send it.

The default behavior should be to send emails automatically, but it’s not working. How can I resolve this issue?

If schedular is not enabled then enable it.

Reference: Frappe.email.queue.flush execution timing - #2 by NCP

@NCP I have the same issues and tried the things before. In my setup it´s like the mails wont get into any queue. The scheduler is active but never gets mail queues. This may come from this commit. I do not know it yet, but it seems that there may be something went broken?

Here are some screens from my freshly installed ERPNext Instance:

Frappe Framework: v15.44.0
ERPNext: v15.38.0

All Installed on fresh Debian Server with Docker and Custom App (Wiki)

CC: @blaggacao

Is RQ Jobs also enabled?

Yes it is. And it might sound crazy, but it seems to work now… I did not change anything in the background but after playing a while with different features of erpnext the scheduler works fine now. In the beginning I did only have some delete connections jobs in the scheduler but now it seems to work… I do not know if it has to be triggered by something to run normal, acutally I do not know why it works now at all… I tried for >1hour this morning with no success, but now it seems to magically work. In the morning there wasnt the queue.flush job in the schedular (But RQ Jobs was active!) at all…

First I have tried dockerized version of frappe but I did not manage to make it work so I shifted to use bench way and what cause the problem after installing with bench is

frappe-bench-web:frappe-bench-node-socketio process

you can find status for it with sudo supervisorctl status (only if install frappe using bench way)

if the process state not running and exit, it will cause the email never send from the queue automatically and instead you can send it manually. So make sure to run it and things will be good after that.

Where you able to confirm or pin it down?

I can’t spot any change in behavior from the diff that you had linked, thus far. :person_shrugging: