Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] E-mail notifications not sent #807

Open
joseon-penggwin opened this issue Jul 31, 2020 · 11 comments
Open

[Bug] E-mail notifications not sent #807

joseon-penggwin opened this issue Jul 31, 2020 · 11 comments

Comments

@joseon-penggwin
Copy link

Hi,

I'm currently trying to get E-mail notifications working.

After uploading a file, the user is prompted the message: E-mail notifications have been sent.

I tried debugging in send-email.php with...:

$this->send_mail->SMTPDebug = 2;

...but there is no Error in the log file and there is no E-mail sent, not the user or to the admin.

I tried with SMTP, Gmail and different authentication methods (None, SSL, TLS).


Any ideas / fixes?

Thank you and kind regards

ProjectSend version r1070

@joseon-penggwin
Copy link
Author

Any updates?

@joseon-penggwin
Copy link
Author

@ignacionelson Can I ping you here? I haven't heard anything in two weeks.

@DracosAlpha
Copy link

Just installed r1070. None of the options available for sending email work for me, except PHPMail, which obviously ends up in spam systematically because there's no DKIM.

I have tried:
Gmail
(we have the business version. Less secure apps is on. I unlocked the Captcha just in case https://accounts.google.com/DisplayUnlockCaptcha)
SMTP through Gmail
(same as above)
Local mail service (I'm on cPanel)
localhost SMTP
dns-based SMTP
Nothing works in all permutations of 465/587/26 None/SSL/TLS
A cornucopia of nothing.
A lifeline would be appreciated here, even if it's tied to a boat anchor.

@ignacionelson
Copy link
Collaborator

Hi @DracosAlpha
Please try with the beta version of the next release. It has an updated version of phpmailer which is used for sending regarding of the options you choose. It also includes a page under Tools that let's you test email and gives you the result. You might find the error code there.
https://www.projectsend.org/download/343/

gmail can give you a special password for connecting apps that send email, instead of using the regular one of the account. Can you check if that lets you connect?

@ignacionelson
Copy link
Collaborator

@joseon-penggwin sorry for missing your message!

@DracosAlpha
Copy link

@ignacionelson Thanks so much for getting back to me.
Well things didn't go well. I tried upgrading the files to the beta version first, but that caused an inability to log in. I had to wipe everything and reinstall, and now the reinstallation gives this message:
There was an error writing to the database.
PDOException: SQLSTATE[42000]: Syntax error or access violation: 1067 Invalid default value for 'updated_at' in .../install/index.php:60 Stack trace: #0
.../install/index.php(60): PDO->prepare('CREATE TABLE IF...') #1
.../install/index.php(153): try_query(Array) #2 {main}
So basically everything's gone and I am no closer to figuring out why. LOL
I have to laugh about it.

@ignacionelson
Copy link
Collaborator

@DracosAlpha thanks for testing, and sorry that you found those errors!
Seems like the updated_at field on the user meta table was not being created correctly. I've replaced the file (on the same link) in case you are interested in trying again.
Regarding the issue updating a current install, I've also applied a few updates that should hopefully fix this.
What php version are you using? Please keep in mind that this new version requires at least 7.0

@DracosAlpha
Copy link

@ignacionelson Thanks a lot for this version. It helps to track down the error.
This is what I'm getting in the connection window:

Connection failed. Error #2: stream_socket_enable_crypto(): Peer certificate CN=srv7.varibase.com' did not match expected CN=smtp.gmail.com' [/home/varibase/public_html/fichiers/vendor/phpmailer/phpmailer/src/SMTP.php line 454]
SMTP Error: Could not connect to SMTP host.
CLIENT -> SERVER: QUIT

@ignacionelson
Copy link
Collaborator

Thanks for testing!
I've found this:
https://stackoverflow.com/questions/52765525/connection-failed-error-2-stream-socket-enable-crypto-peer-certificate-wit

So with that in mind, I've added those 3 options in the email settings page.
Sorry, could you please try again? I've updated the zip file with this fix (same url as before) I believe this should solve it!
https://www.projectsend.org/download/343/

@DracosAlpha
Copy link

Hi Ignatio.
Again, really appreciate your efforts.
Unfortunately this version gives a 500 error right after upload.
I was able to run the installation by going directly to /install/index.php, but installation ended with errors, and the main page still gives a 500 error. I have tried to locate an error log or something that would give an indication of what the problem is, but I find nothing. I have dropped all the tables again, and started over, but no change. 500 error on upload. Install has errors. Main page is still showing a 500 error.

@ignacionelson
Copy link
Collaborator

Sorry about this :( Is it possible that you are running the latest version of mariadb and php 7.2 or lower? There's a mariadb bug that might be what's happening in this case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants