Hi Federico.

Maybe if we were starting from scratch having a default would be the right
course โ€” "maybe", I didn't think it through yet, or look at why the
original decision went the way it did โ€” but I don't think changing it is
worth the disruption, or the difficulty of going through the deprecation
process.

(Why is "Just give it a value in your settings" not OK? ๐Ÿค”)

Around core.mail, there's a cluster of tickets that I'm hoping to pull into
a project idea for this year's GSoC โ€” see...

- [Add Settings EMAIL_FQDN by Jrief ยท Pull Request #13728 ยท Django/Django](
https://github.com/django/django/pull/13728)

- [Ui/Django-post_office: A Django App That Allows You to Send Email
Asynchronously in Django. Supports HTML Email, Database Backed Templates
and Logging.](https://github.com/ui/django-post_office)

- [Proposal on How Add Configuration Options to Email Backends](
https://groups.google.com/g/django-developers/c/R8ebGynQjK0)


... and linked threads.


... and linked threads.

One result of that (if all comes to pass) should hopefully be better
customizability of your email backends, so you'd be free to set a default
in your own backend, without the BC concerns for others.

So that's not a, yes, let's change it, but hopefully it doesn't leave you
without optimism ๐Ÿ™‚

Kind Regards,

Carlton

On Thu, 17 Nov 2022 at 16:33, Federico Capoano <federico.capo...@gmail.com>
wrote:

> Hi all,
>
> Why is there no default for EMAIL_TIMEOUT?
>
> Applications built in Django can potentially stall indefinitely if email
> sending starts to hang (eg: if the SMTP server is overloaded), when this
> happens, since there's no timeout, there's also no error being logged, so
> it's very hard and time consuming to debug.
>
> Wouldn't it be better to set a timeout? Some high value like 2 minutes
> which wouldn't really make sense to wait any longer, so at least if and
> when this happens, developers will find error traces in the logs and
> quickly understand where the problem is coming from, instead of spending
> hours to debug it like I did in the past week.
>
> Alternatively, we could set a default timeout only if
> "socket.getdefaulttimeout()" returns None, just to avoid applications
> stalling indefinitely, which is something that has been happening to me
> lately.
>
> Best regards
> Federico Capoano
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/CAERYH6Vs6%2BWnJMsw95Uc_b006PZ2N_Pr%3DNgx4ztPDkgjVbkivA%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-developers/CAERYH6Vs6%2BWnJMsw95Uc_b006PZ2N_Pr%3DNgx4ztPDkgjVbkivA%40mail.gmail.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAJwKpyRt%3D3AfDF3ygyn2XY9X7OtqzbWJ8U0VwH0KhwW-KJwzQg%40mail.gmail.com.
  • Set... Federico Capoano
    • ... Carlton Gibson
      • ... Arthur Pemberton
        • ... Mariusz Felisiak
          • ... Michiel Beijen
            • ... Federico Capoano
              • ... Federico Capoano
                • ... 'Adam Johnson' via Django developers (Contributions to Django itself)

Reply via email to