Lorenzo Ancora added the comment:

(msg259748) ok, then I propose to correct 
https://docs.python.org/dev/library/smtpd.html?highlight=q#smtpd.SMTPServer 
from:

.. class:: SMTPServer(localaddr, remoteaddr, data_size_limit=33554432,\
                      map=None, enable_SMTPUTF8=False, decode_data=True)

   Create a new :class:`SMTPServer` object, which binds to local address
   *localaddr*.  It will treat *remoteaddr* as an upstream SMTP relayer.  It
   inherits from :class:`asyncore.dispatcher`, and so will insert itself into
   :mod:`asyncore`'s event loop on instantiation.


To:


.. class:: SMTPServer(localaddr, remoteaddr, data_size_limit=33554432,\
                      map=None, enable_SMTPUTF8=False, decode_data=True)

   Creates a new :class:`SMTPServer` object, which binds to local address
   *localaddr* and uses *remoteaddr* as an upstream SMTP relayer.
   Both parameters should be a tuple in the form ``("host", portnumber)``, 
where *host* is a valid IP/FQDN.
   The object will insert itself into :mod:`asyncore`'s event loop on 
instantiation (inherits from :class:`asyncore.dispatcher`) and can be started 
with a call to :class:`asyncore.loop`.

---

These clarifications should be also inserted in the source code as heredocs 
(without the Sphynx syntax).
I really think that those changes will make the use of smtpd easier.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue26209>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to