Nodemailer with Gmail error: 454 4.7.0 Cannot authenticate due to temporary system problems
<p>I am using nodemailer module with my nodejs/express.js app. </p>

<p>I am using gmail as the transporter. </p>

<p>It seems like every 20 successful emails sent, I will get this error:</p>

<p><strong>454 4.7.0 Cannot authenticate due to temporary system problem</strong></p>

<p>I'm testing out an invoice system so I'm regularly sending an email to the same email address for testing.</p>

<p>I am not using Google apps and I have set Gmail security to work with low security apps. </p>

<p>Invoices are important and if I cant guarantee all invoices will get sent to my customers, its going to be bad.</p>

<p>Is this normal? </p>

<pre><code>app.get('/thankyou', function(req,res) {

  var transporter = nodemailer.createTransport({
    service: 'Gmail',
      auth: {
      user: 'somethinggggg@gmail.com',
      pass: 'password here'
      }
    });

   res.render('thankyou_email', function(err,html) {

     var mailOptions = {
       from: 'John Doe &lt;somethinggggg@gmail.com&gt;',
       to: 'someoneee@icloud.com',
       subject: 'Your order was received',
       html: html
     };

     transporter.sendMail(mailOptions, function(error, info) {
       if(error) {
        console.log('error1: ' + error);
        transporter.sendMail(mailOptions, function(error, info) {
          if(error) {
            console.log('error2: ' + error);
          } else {
            console.log('cool bro everything works2');
            console.log(info);
          }
        });
       } else {
        console.log('cool bro everything works');
        console.log(info);
       }
     });

     res.render('thankyou_page');
});
</code></pre>

<p>As you can see, if I have an error I try to resend the email again, but still I receive the same error.</p>

<p>Also notice that I am using res.render() twice. I thought this was weird but it still works. The first res.render() I am using to generate the html for the email, and the last res.render() is to render the html in the response back to the client. I used to get an error about sending headers twice, but I don't see that error no more. Nevertheless ,it still worked. </p>

<p>Whose fault is this? Me? Nodemailer? Gmail?
If I were to sign up for Google apps will I still have this problem? </p>