Request timed out on Payment Request and Email Settings

We are unable to submit payment requests. Pressing save works great and it becomes draft status, but when I press “Submit” the request times out and eventually I receive a dialog saying the request has timed out. Other records seem to submit just fine. I noticed some recent changes / fixes on payment requests in the git log, and I wonder if that has introduced something that is causing it to timeout?

I have not yet configured email settings, so I thought it might be related to that. However, when I tried to configure a new email domain, I also get the same timeout error when I try to save. I am not sure if this is a bug in the code, or something I have mis-configured. If I need to open an issue on github instead, please let me know.

I am happy to provide any information that may be helpful.

web.error.log: "[CRITICAL] WORKER TIMEOUT (pid:23343)"

Current ERPNext commit: commit 0d0d3bacd7d31055b575639dc9bf2595ba229caf

Bellow is a copy of the Post parameters as recored by firebug (with some personal details removed):

doc={“naming_series”:“PR”,“creation”:“2017-05-10 19:21:25.485245”,“doctype”:“Payment Request”,“currency”:“OMR”,“owner”:“myemail@mydomain”,“message”:“



Requesting payment against Sales Order SO-00001 for amount (removed)

\n\n<a href=”{{ payment_url }}">Make Payment\n\n

If you have any questions, please get back to us.


Thank you for your business!

",“subject”:“Payment Request for SO-00001”,“reference_doctype”:“Sales Order”,“modified_by”:“myemail@mydomain”,“docstatus”:0,“status”:“Draft”,“reference_name”:“SO-00001”,“mute_email”:0,“email_to”:“myemail”,“print_format”:“Standard”,“grand_total”:17.55,“name”:“PR00001”,“idx”:0,“modified”:“2017-05-10 19:21:25.485245”,“make_sales_invoice”:0,"__last_sync_on":“2017-05-10T15:25:39.977Z”}
1 Like

I have setup the “Notifications” email account. However, I am still having the timeout error. Is it normal for submitting a payment request to take longer than 2 minutes? Any suggestions as to which logs I should be looking at?

Did you find any solution on this?

Yes. In my case it was related to the email provider requiring SSL instead of startTLS. Since ERPNext tries to use StartTLS, the connection to the email server was timing out. I would check your email settings. In my case, I had to patch the email code to enable SSL/TLS without StartTLS. However, a similar timeout could be caused by a bad port number or server hostname.

1 Like

Thank you. Now we’re testing with gmail (that we do not like to use at all) since the outgoing settings for our own domain were not working and even if we tried with many other email domains, nothing were really working as outgoing email, incoming yes.