dawidd6 / action-send-mail

:gear: A GitHub Action to send an email to multiple recipients
MIT License
443 stars 186 forks source link

Fix for issue #196 #197

Closed kroese closed 6 months ago

kroese commented 7 months ago

Fixes issue #196

dawidd6 commented 6 months ago

Could you somehow simplify those changes? Maybe we can use some third-party npm package providing a functionality for retry-backoff mechanism?

kroese commented 6 months ago

I have almost zero experience with NodeJS / npm. I just wrote that code in the Github editor without any development enviroment.

Its just a simple loop, and already does something similar to retry-backoff by increasing the amount of minutes to wait each time the try fails. I tested it for several days, and the highest number of tries needed before Gmail accepted the message was 7 tries, so the limit of 10 seems a sane value.

If you want to do something more fancy, no problem. But for my usecase this loop already is a big improvement, because before the action failed multiple times per day (using the Google Workspaces smtp server) and now it always finishes succesfully.

dawidd6 commented 6 months ago

Alright, thanks.