SMTP wrong Configuration or Exception - User not informed
Closed this issue · 4 comments
app-generator commented
If the SMTP credentials are wrong, the registration process fails in the background but the user is not informed.
Here are the steps to reproduce this:
- Save wrong values in
.env
for SMTP settings - Create a new user
- Check the runtime log and UI message
@topstar210 please take a look.
TY!
UI
Logs
[next-auth][warn][NO_SECRET]
https://next-auth.js.org/warnings#no_secret
Error: Can't send mail - all recipients were rejected: 550 No Such User Here"
at SMTPConnection._formatError (webpack-internal:///(rsc)/./node_modules/nodemailer/lib/smtp-connection/index.js:611:19)
at SMTPConnection._actionRCPT (webpack-internal:///(rsc)/./node_modules/nodemailer/lib/smtp-connection/index.js:1297:28)
at SMTPConnection.eval (webpack-internal:///(rsc)/./node_modules/nodemailer/lib/smtp-connection/index.js:1255:30)
at SMTPConnection._processResponse (webpack-internal:///(rsc)/./node_modules/nodemailer/lib/smtp-connection/index.js:748:20)
at SMTPConnection._onData (webpack-internal:///(rsc)/./node_modules/nodemailer/lib/smtp-connection/index.js:584:14)
at SMTPConnection._onSocketData (webpack-internal:///(rsc)/./node_modules/nodemailer/lib/smtp-connection/index.js:143:48)
at TLSSocket.emit (node:events:514:28)
at addChunk (node:internal/streams/readable:343:12)
at readableAddChunk (node:internal/streams/readable:316:9)
at Readable.push (node:internal/streams/readable:253:10)
at TLSWrap.onStreamRead (node:internal/stream_base_commons:190:23)
at TLSWrap.callbackTrampoline (node:internal/async_hooks:130:17) {
code: 'EENVELOPE',
response: '550 No Such User Here"',
responseCode: 550,
command: 'RCPT TO',
rejected: [ 'whatever@appseed.us' ],
rejectedErrors: [
topstar210 commented
Please share your email SMTP server via DM
app-generator commented
You can use the wrong settings.
The nominal case is when the user gets an error message that suggests the backend issue.
TY!
topstar210 commented
in spite of the wrong setting in nextauth, nextauth gives OK request when send the email. and then giving smtp issue after a long time
so can't detect and display the error on UI
app-generator commented
Closing. TY @topstar210.