Emails not sending even though .env file settings are correct

Hello,

I am having problems with Quotes & Invoices emails not sending.

  1. I have set invoice ninja emails to “default”
  2. I have the .env settings all correct. My username, password & all other settings are correct. I use these settings ok with my main website and they work fine.
  3. I have set the QUEUE to sync, QUEUE_CONNECTION=sync
  4. I just want the emails to send automatically when i press the send button in Invoice Ninja.
  5. When i click the send button it shows as sent but no emails are ever sent or received.
  6. I have also checked the error_log file and it is blank with no errors reported.

No matter what i do no emails will send. I have tried everything. I am also not able to get the crons to work. I have followed all guides and am using WHM cPanel as my hosting. This is my own server and is not shared hosting. The red triangle will not disappear no matter how i set the cron using the guide.

Any help here would be much appreciated as i really need to get this working.

Please advise, Wayne

I’m having the exact same issue

Hi,

Are there any email errors in the system logs on the dashboard?

What do you see when running the cron from the CLI without the >> part?

Actually, can you help me with this part, I installed IN with softculous, everything was working fine up until the last update. However, I have always had issues with the crons job not being enabled. I tried falling the instructions on the users guide to fix it and it hasn’t work, I still get Crons not enabled. What should I do?

Same advice… what do you see when running the cron from the CLI without the >> part?

what is CLI? I’m not a developer

CLI is the command line interface, your webhost may provide a terminal app which enables you to SSH into the server.

sorry, I have no clue. I use cPanel and webhost is NameCheap

Can you share your cron configuration?

Two problems I see: the command should start with cd and the it should run every minute.

Still having the same issues, including found that I also get a error 500 when I try to view the e-invoices

@david do you have any suggestions?

Does this help any?

[2023-05-11 22:19:29] production.ERROR: Attempt to read property “iso_3166_2” on null {“userId”:1,“exception”:"[object] (ErrorException(code: 0): Attempt to read property "iso_3166_2" on null at /home/pacedvgq/invoices.eleana-us.com/app/Services/Invoice/EInvoice/ZugferdEInvoice.php:76)
[stacktrace]

Found the issue, am able to do have a work around. In email settings I had e-invoice enabled, when I disabled it I was able to email invoices. I don’t need e-invoices necessarily to be sent, it would have been nice, but not necessary if I can keep sending emails.

Hello Hillel,

There are no errors i can see. The error_log file is blank. Am i able to pm you somehow and send you the access info so you can have a look? I’ve tried every suggestion on here including the CL Laravel refresh and am out of ideas.

Thank you, Wayne

Here are the last 2 entries from the Laravel Log,

[2023-05-05 19:12:55] production.INFO: Broadcasting [App\Events\Invoice\InvoiceWasCreated] on channels [simple-channel] with payload:
{
“id”: “value”,
“socket”: null
}
[2023-05-08 19:19:49] production.INFO: Broadcasting [App\Events\Invoice\InvoiceWasCreated] on channels [simple-channel] with payload:
{
“id”: “value”,
“socket”: null
}

Are there any email errors in the system logs on the dashboard?

My emails are going into the spam folder.

I suggest sending a test invoice to https://www.mail-tester.com to check for any issues