Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-08-20 Thread Mike Edmunds
PRs are now open: 1. Updated test cases (on existing legacy implementation): https://github.com/django/django/pull/18502 2. Change to modern email API: https://github.com/medmunds/django/pull/2 A few changes of note from the original plan, based on things discovered during implementati

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-22 Thread Mike Edmunds
; I am writing to inform you that we have reviewed and decided to accept the > proposal to upgrade django.core.mail to Python's modern email API. We > believe that this upgrade will bring significant improvements to our > system's performance and maintainability. > &g

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-21 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
well. >> I am writing to inform you that we have reviewed and decided to accept the >> proposal to upgrade `django.core.mail` to Python's modern email API. We >> believe that this upgrade will bring significant improvements to our >> system's performance and

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-21 Thread Othniel Davidson
Thank you for the update On Sat, Jul 20, 2024 at 15:26 Pankaj Kumar wrote: > Hi Sir, >I hope this message finds you well. > > I am writing to inform you that we have reviewed and decided to accept the > proposal to upgrade django.core.mail to Python's modern email AP

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-20 Thread Pankaj Kumar
Hi Sir, I hope this message finds you well. I am writing to inform you that we have reviewed and decided to accept the proposal to upgrade django.core.mail to Python's modern email API. We believe that this upgrade will bring significant improvements to our system's perfo

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-06 Thread Mike Edmunds
On Saturday, July 6, 2024 at 11:17:35 AM UTC-7 Florian Apolloner wrote: On Saturday, July 6, 2024 at 12:30:32 AM UTC+2 Mike Edmunds wrote: Incidentally, I thought there was (used to be?) a policy that internal undocumented APIs were fair game for use by third-party libraries, subclassing, etc

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-06 Thread Mike Edmunds
Ticket created: https://code.djangoproject.com/ticket/35581 On Friday, July 5, 2024 at 5:27:28 PM UTC-7 Mike Edmunds wrote: > Thanks to everyone for the feedback so far. > > It looks like all the responses to date are generally positive, and I > haven't seen any objections, so I'm going to open

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-06 Thread Florian Apolloner
On Saturday, July 6, 2024 at 12:30:32 AM UTC+2 Mike Edmunds wrote: Incidentally, I thought there was (used to be?) a policy that internal undocumented APIs were fair game for use by third-party libraries, subclassing, etc., so long as they didn't start with an underscore. (But "private" undersc

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-06 Thread Jörg Breitbart
We recently had quite a struggle with programming a newsletter extension for django-cms, mainly around the html-mails with CID embedded images. I am not deep into the details, still want to express my support for the idea to reshape the email abstraction in django, thus +1. Cheers, Jörg -- Y

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-05 Thread Mike Edmunds
Thanks to everyone for the feedback so far. It looks like all the responses to date are generally positive, and I haven't seen any objections, so I'm going to open a ticket. (Of course, additional feedback—positive or negative—and advice is very much appreciated.) Cheers, Mike -- You receive

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-05 Thread Mike Edmunds
About MIMEBase attachments: I propose we continue supporting them in Django, without deprecation, for now. We can investigate adding support for the equivalent in Python's modern email API later, as a separate proposal. More details… On Wednesday, June 26, 2024 at 6:28:06 PM UTC-7 I wrote: > Tr

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-07-05 Thread Mike Edmunds
On Friday, June 28, 2024 at 1:07:35 PM UTC-7 Florian Apolloner wrote: > Are all of those documented? If not we can simply remove them (especially if the deprecation implementation turns out to be a PITA). It sort of depends on the definition of "documented." I've dug into real-world usage; resul

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-30 Thread Ronny V.
Adding my support for the suggested approach. Start small and central and step-by-step. 👍 > (I'm going to add a link in django-anymail's "you probably don't need proprietary ESP templates " docs.) Thanks! Much appreciated! And thx on your

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-28 Thread Florian Apolloner
Hi Mike, overall the plan sounds good. I especially like the approach to "fix" the tests first. This can happen in an extra merge request and reviewed independently so we can be sure that we are still testing what we want to test before moving to the tricky parts. On Thursday, June 27, 2024 at

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-27 Thread Mike Edmunds
> focus it on purely the strictly necessary parts to update to the new API … before dealing with potentially contentious things like EmailMultiAlternatives, MIMEBase, etc. Appreciate the advice. I'll try to keep EmailMultiAlternatives and see whether that makes the new code hard to follow. Sad

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-27 Thread Paolo Melchiorre
I agree with the approach suggested by Tom. And thanks for proposing this enhancement. Ciao, Paolo On Thu, Jun 27, 2024, 11:14 Tom Carrick wrote: > I'm in favour of this change, and nice that you're thinking about the > future, but if you're going to write a ticket for this I would focus it on

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-27 Thread Tom Carrick
I'm in favour of this change, and nice that you're thinking about the future, but if you're going to write a ticket for this I would focus it on purely the strictly necessary parts to update to the new API, and when that is done, make more proposals to simplify the API as you suggest. I say this j

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-26 Thread Mike Edmunds
Since the early feedback seems positive (though we're still waiting for more votes), here's some additional detail on the changes I think would be involved to update django.core.mail to use Python's modern email API. (See my earlier message

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-25 Thread Mike Edmunds
> After my comment in the steering council vote and in-person conversation with Jake, I believe the SMTP backend will not be implemented for DEP 14 Then I can improve my earlier response: I *am confident* this proposal will have *no impact* on background workers. :-) - Mike On Tuesday, June 25

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-25 Thread Mike Edmunds
Hi Ronny, django-pony-express looks really interesting, thanks. (I'm going to add a link in django-anymail's "you probably don't need proprietary ESP templates " docs.) I think django-pony-express is very complementary to this proposal, both

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-25 Thread Ronny V.
Hi all! Jakob Rief pointed this discussion out to me. I've been going around lately to make some advertisement for my idea of class-based emails. I've implemented a package called "django-pony-express" which in a nutshell provides to things: * A class-based way of creating new emails (very sim

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-25 Thread 'Adam Johnson' via Django developers (Contributions to Django itself)
After my comment in the steering council vote and in-person conversation with Jake, I believe the SMTP backend will not be implemented for DEP 14 : https://forum.djangoproject.com/t/steering-council-vote-on-background-tasks-dep-14/31131/20 On Tue, 25 Jun 2024, at 10:27, Arthur Pemberton wrote: >

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-25 Thread Arthur Pemberton
> The background workers proposal will implement a new background SMTP EmailBackend (in django.core.mail.backends). I had missed that fact. Thanks for the explanation. I for one think that this is a good proposal -- this would modern transactional email sending. - Arthur On Mon, Jun 24, 2024

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-24 Thread Mike Edmunds
> Would this be designed to be compatible with "Proposal 14: Background Workers"? I wouldn't expect this to impact background workers one way or the other. The same goes for the async email proposal(s) floating around. Virtually all of this work would occur in django.core.mail.message, where P

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-23 Thread Arthur Pemberton
Would this be designed to be compatible with "Proposal 14: Background Workers"? On Sun, Jun 23, 2024 at 10:46 PM Mike Edmunds wrote: > I want to propose updating django.core.mail to replace use of Python's > legacy email.message.Message (and other legacy email APIs) with > email.message.EmailM

Re: Proposal to upgrade django.core.mail to Python's modern email API

2024-06-23 Thread 'Mohamed El-Kalioby' via Django developers (Contributions to Django itself)
+1, I like to help in this On Mon, 24 Jun 2024, 05:46 Mike Edmunds, wrote: > I want to propose updating django.core.mail to replace use of Python's > legacy email.message.Message (and other legacy email APIs) with > email.message.EmailMessage (and other modern APIs). > > If there's interest, I c

Proposal to upgrade django.core.mail to Python's modern email API

2024-06-23 Thread Mike Edmunds
I want to propose updating django.core.mail to replace use of Python's legacy email.message.Message (and other legacy email APIs) with email.message.EmailMessage (and other modern APIs). If there's interest, I can put together a more detailed proposal and/or ticket, but was hoping to get some