Django

Code

Ticket #1555 (closed: fixed)

Opened 3 years ago

Last modified 2 years ago

[patch][magic-removal] Fix to allow for sending email on non-standard SMTP ports.

Reported by: bde3@cornell.edu Assigned to: adrian
Milestone: Component: Core framework
Version: magic-removal Keywords: mail smtp port
Cc: Triage Stage: Unreviewed
Has patch: 1 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

Fix to allow django.core.mail.send_mail() to work with a non-standard SMTP port. (i.e. not 25)

Attachments

mail_with_port.diff (0.9 kB) - added by bde3@cornell.edu on 03/29/06 10:38:44.
patch to allow any SMTP port

Change History

03/29/06 10:38:44 changed by bde3@cornell.edu

  • attachment mail_with_port.diff added.

patch to allow any SMTP port

04/04/06 03:00:03 changed by SmileyChris

  • milestone set to Version 0.92.

Good, purposeful and easily implemented patch, bde@.

Alternatively, if we didn't want to add another setting, then perhaps EMAIL_HOST could be made to check for a :port. In django/core/mail.py:

port = 25
host = settings.EMAIL_HOST
if ':' in host:
    host, port = host.split(':', 1)
    port = int(port)
server = smtplib.SMTP(host, port) 

You'd also want to change the comment for EMAIL_HOST in django/conf/global_settings.py to reflect this new functionality.

04/10/06 22:23:04 changed by adrian

  • status changed from new to closed.
  • resolution set to fixed.

(In [2665]) Fixed #1555 -- Added EMAIL_PORT setting. Thanks, bde3

10/24/06 15:17:23 changed by adrian

  • milestone deleted.

Milestone Version 0.92 deleted


Add/Change #1555 ([patch][magic-removal] Fix to allow for sending email on non-standard SMTP ports.)




Change Properties
Action