classification
Title: SMTP.local_hostname is undocumented
Type: enhancement Stage: resolved
Components: Documentation, email Versions: Python 3.3, Python 3.4, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: akuchling, barry, berker.peksag, docs@python, jonash, python-dev, r.david.murray
Priority: normal Keywords: patch

Created on 2013-06-10 10:24 by jonash, last changed 2013-06-23 20:16 by r.david.murray. This issue is now closed.

Files
File name Uploaded Description Edit
issue18179.diff berker.peksag, 2013-06-13 08:34 review
Messages (5)
msg190898 - (view) Author: Jonas H. (jonash) * Date: 2013-06-10 10:24
The Sphinx docs don't contain any explanation for `local_hostname`.
msg190900 - (view) Author: Berker Peksag (berker.peksag) * (Python committer) Date: 2013-06-10 11:47
The docstring of the SMTP class says:

"If specified, `local_hostname` is used as the FQDN of the local host.  By default, the local hostname is found using socket.getfqdn()."

See Lib/smtplib.py:226.
msg190904 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2013-06-10 12:48
SMTP.local_hostname is probably a private attribute of the SMTP class, dating from before we started getting strict about having private attributes start with '_'.  However, I see no reason to keep it private; we might as well just document it, since I'm sure people are using it and there is no reason to expect to want to change its behavior.
msg191726 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2013-06-23 20:12
New changeset 3685d8074203 by R David Murray in branch '3.3':
#18179: document the local_hostname parameter.
http://hg.python.org/cpython/rev/3685d8074203

New changeset b10fae8c185c by R David Murray in branch 'default':
Merge #18179: document the local_hostname parameter.
http://hg.python.org/cpython/rev/b10fae8c185c

New changeset c8914dbe6ead by R David Murray in branch '2.7':
#18179: document the local_hostname parameter.
http://hg.python.org/cpython/rev/c8914dbe6ead

New changeset ffcf46316e1f by R David Murray in branch '3.3':
#18179: reflow paragraphs.
http://hg.python.org/cpython/rev/ffcf46316e1f

New changeset 627e3096340e by R David Murray in branch 'default':
Merge #18179: reflow paragraphs.
http://hg.python.org/cpython/rev/627e3096340e

New changeset 9f1f83d23ec4 by R David Murray in branch '2.7':
#18179: reflow paragraphs.
http://hg.python.org/cpython/rev/9f1f83d23ec4
msg191727 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2013-06-23 20:16
Thanks Berker.  I edited your patch to (a) use 'Otherwise' instead of 'By default', which is a change from the original docstring that I think makes it clearer, (b) add words about what the local_hostname is used for (the HELO/EHLO commands) and (c) in SMTP_SSL and LMTP, just refer to the SMTP class (like LMTP already did).  I also updated the docstrings similarly.
History
Date User Action Args
2013-06-23 20:16:19r.david.murraysetstatus: open -> closed
resolution: fixed
messages: + msg191727

stage: patch review -> resolved
2013-06-23 20:12:49python-devsetnosy: + python-dev
messages: + msg191726
2013-06-14 20:24:06akuchlingsetnosy: + akuchling
2013-06-13 08:34:40berker.peksagsetfiles: + issue18179.diff
keywords: + patch
stage: needs patch -> patch review
2013-06-10 12:48:54r.david.murraysetnosy: + barry, r.david.murray
messages: + msg190904

components: + email
type: enhancement
stage: needs patch
2013-06-10 11:47:04berker.peksagsetnosy: + berker.peksag

messages: + msg190900
versions: - Python 2.6, Python 3.1, Python 3.2, Python 3.5
2013-06-10 10:24:28jonashcreate