Opened 18 years ago
Closed 17 years ago
#4707 closed (wontfix)
Allow attachements in mail_{admins,managers}
Reported by: | Owned by: | Thejaswi Puthraya | |
---|---|---|---|
Component: | Core (Mail) | Version: | dev |
Severity: | Keywords: | sprintdec01 | |
Cc: | Triage Stage: | Ready for checkin | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
The patch adds a parameter to send attachements with mail_admins() and mail_managers() methods.
Attachments (2)
Change History (7)
by , 18 years ago
Attachment: | mail_attachements.diff added |
---|
comment:1 by , 18 years ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
comment:2 by , 18 years ago
Component: | Uncategorized → django.core.mail |
---|---|
Resolution: | wontfix |
Status: | closed → reopened |
Triage Stage: | Unreviewed → Design decision needed |
Thinking this over a bit more, there might be a case for admin and manager mail to allow it, since the equivalent code is a bit fiddly to write.
(We can't use the existing patch, though, since it misspells "attachment" everywhere.)
comment:3 by , 17 years ago
Perhaps it is helpful to tell for what I am needing this. Whenever a server error occurs, I mail a traceback.html attachment (which is manually generated from the django debug error view) using the mail_admins() method. Then I can open the traceback.html on my local box and analyze the problem without touching the server which runs in non-debug mode.
I will send an updated patch without the spelling error once I get to it.
by , 17 years ago
Attachment: | mail_attachments_1.diff added |
---|
corrected the typos in the previous diff
comment:4 by , 17 years ago
Keywords: | sprintdec01 added |
---|---|
Owner: | changed from | to
Status: | reopened → new |
Triage Stage: | Design decision needed → Ready for checkin |
comment:5 by , 17 years ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
This isn't worth extending the API for. If you want to add extra stuff beyond want mail_admins does, you can write your own handler and an exception middleware. The support already exists for that.
As explained in the documentation, the whole idea of creating the more object-oriented design for email was to avoid adding more and more parameters to the existing methods. Those methods are there for backwards compatibility only. They won't be extended with any new parameters (if you want to use the new features, you have to change your code anyway. Switching to using EmailMessage takes no time).