I don't think settings create any harm. They seem cleaner than suggesting 
subclassing the backend. If I'm understanding correctly, that would force 
everyone to write something like:

class MySMTPBackend(smtp.EmailBackend)
    def __init__(self, *args, **kwargs):
        super().__init__(*args, keyfile='<my keyfile>', **kwargs)

That sort of code probably isn't suitable for `settings.py` itself which 
means configuration data like `'<my keyfile>'` is scattered elsewhere, or 
else developers are forced to write boilerplate and create their own 
settings to refer to `'<my keyfile>'`.

See also past discussion "Move SMTP / email settings to a dictionary" 
(wontfix)
https://code.djangoproject.com/ticket/22734
On Thursday, November 26, 2020 at 5:03:19 AM UTC-5 carlton...@gmail.com 
wrote:

> Hi Michiel.
>
>
> On 25 Nov 2020, at 17:53, Michiel Beijen <michiel...@gmail.com> wrote:
>
> the old ones should be marked deprecated and
> probably should have been marked as such some Django releases ago.
>
>
> There you are, super. 👍
>
> Thank you for your input! 
>
> Kind Regards,
>
> Carlton
>
>
>
>
>

-- 
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/5223f927-f30b-40f7-bba0-a7c2f30e6a28n%40googlegroups.com.

Reply via email to