Skip to content

Scrapy, a fast high-level web crawling & scraping framework for Python.

some email doc improvments

Pablo Hoffmandfdc04c28c9d
diff --git a/scrapy/trunk/docs/ref/email.rst b/scrapy/trunk/docs/ref/email.rst
index 6d3ade830..cc56c4aee 100644
--- a/scrapy/trunk/docs/ref/email.rst
+++ b/scrapy/trunk/docs/ref/email.rst
@@ -1,4 +1,4 @@
-.. _topics-email:
+.. _ref-email:
=============
Sending email
@@ -29,15 +29,18 @@ MailSender class
================
MailSender is the class used to send emails from Scrapy. It's
-currently only a warpper over the (IO blocking) smtplib
+currently only a wrapper over the (IO blocking) `smtplib`_
library but it's gonna be ported to Twisted soon.
+.. _smtplib: http://docs.python.org/library/smtplib.html
+
.. class:: scrapy.mail.MailSender(smtphost, mailfrom)
- ``smtphost`` is a string with the SMTP host to use for sending the emails
+ ``smtphost`` is a string with the SMTP host to use for sending the emails.
+ If omitted, :setting:`MAIL_HOST` will be used.
``mailfrom`` is a string with the email address to use for sending messages
- (in the ``From:`` header)
+ (in the ``From:`` header). If omitted, :setting:`MAIL_FROM` will be used.
.. method:: send(to, subject, body, cc=None, attachs=None)
diff --git a/scrapy/trunk/docs/ref/settings.rst b/scrapy/trunk/docs/ref/settings.rst
index 125b3e16e..c2c837a18 100644
--- a/scrapy/trunk/docs/ref/settings.rst
+++ b/scrapy/trunk/docs/ref/settings.rst
@@ -441,9 +441,18 @@ MAIL_FROM
Default: ``'scrapy@localhost'``
-Scope: ``scrapy.mail``
+Email to use as sender address for sending emails using the :ref:`Scrapy e-mail
+sending facility <ref-email>`.
-Host to use for sending notification emails from Scrapy.
+.. setting:: MAIL_HOST
+
+MAIL_HOST
+---------
+
+Default: ``'localhost'``
+
+Host to use for sending emails using the :ref:`Scrapy e-mail sending facility
+<ref-email>`.
.. setting:: MEMDEBUG_ENABLED