Skip to content

Commit 332d7bc

Browse files
committed
Many small documentation tweaks
Removed the quickstart section as it's not necessary. The README as an introductory example now, and the current documentation structure is better now.
1 parent 5bb8fdb commit 332d7bc

File tree

6 files changed

+28
-37
lines changed

6 files changed

+28
-37
lines changed

AUTHORS.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
11
IMAPClient was created by Menno Finlay-Smits <[email protected]>. The
2-
project is now Nicolas Le Manchet and Menno Finlay-Smits.
2+
project is now maintained by Nicolas Le Manchet and Menno
3+
Finlay-Smits.
34

45
Many thanks go to the following people for their help with this
56
project:
67

8+
- Maxime Lorant
79
- Mathieu Agopian
810
- Chris Arndt
911
- Jp Calderone
@@ -14,7 +16,6 @@ project:
1416
- Mark Hammond
1517
- Johannes Heckel
1618
- Thomas Jost
17-
- Maxime Lorant
1819
- Lukasz Mierzwa
1920
- Naveen Nathan
2021
- Brian Neal

doc/src/advanced.rst

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,15 @@ However if an error is raised when selecting the folder, the connection may be
2222
left open.
2323

2424
IMAPClient may be used as a context manager that automatically closes
25-
connections when they are not needed anymore::
25+
connections when they are not needed any more::
2626

2727
import imapclient
2828

2929
with imapclient.IMAPClient(host="imap.foo.org") as c:
3030
c.login("[email protected]", "passwd")
3131
c.select_folder("INBOX")
3232

33-
Watching a mailbox using idle
33+
Watching a Mailbox Using IDLE
3434
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3535
The IDLE extension allows an IMAP server to notify a client when something
3636
changes in a mailbox. It can be used as an alternative to polling to receive
@@ -39,7 +39,7 @@ new messages.
3939
The concept is simple: the client connects to the server, selects a mailbox and
4040
enters the IDLE mode. At this point the server sends notifications whenever
4141
something happens in the selected mailbox until the client ends the IDLE mode
42-
by issuing a `DONE` command. This is explained in :rfc:`2177`.
42+
by issuing a ``DONE`` command. This is explained in :rfc:`2177`.
4343

4444
.. literalinclude:: ../../examples/idle_example.py
4545

@@ -48,10 +48,6 @@ when maintaining long-lived TCP connections. Users are advised to renew the
4848
IDLE command every 10 minutes to avoid the connection from being abruptly
4949
closed.
5050

51-
Handling large mailboxes
52-
~~~~~~~~~~~~~~~~~~~~~~~~
53-
TODO
54-
5551
Interactive Sessions
5652
~~~~~~~~~~~~~~~~~~~~
5753
When developing program using IMAPClient is it sometimes useful to
@@ -150,8 +146,3 @@ oauth2_refresh_token string OAUTH2 token for refreshing the secret.
150146

151147
Acceptable boolean values are "1", "yes", "true", and "on", for true;
152148
and "0", "no", "false", and "off", for false.
153-
154-
Thread Safety
155-
~~~~~~~~~~~~~
156-
Instances of IMAPClient are NOT thread safe. They should not be shared and
157-
accessed concurrently from multiple threads.

doc/src/api.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,3 +61,8 @@ TLS Support
6161

6262
.. automodule:: imapclient.tls
6363
:members:
64+
65+
Thread Safety
66+
~~~~~~~~~~~~~
67+
Instances of IMAPClient are NOT thread safe. They should not be shared and
68+
accessed concurrently from multiple threads.

doc/src/concepts.rst

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
IMAPClient concepts
1+
IMAPClient Concepts
22
-------------------
33

44
Message Identifiers
@@ -77,13 +77,14 @@ connections and also allows for a high level of control of TLS
7777
parameters if required. It uses the built-in `ssl` package,
7878
provided since Python 2.7.9 and 3.4.
7979

80-
TLS parameters are controlled by passing a ``ssl.SSLContext``
81-
when creating an IMAPClient instance. When ``ssl=True`` is used
82-
without passing a SSLContext, a default context is used. The default
83-
context avoids the use of known insecure ciphers and SSL protocol
84-
versions, with certificate verification and hostname verification
85-
turned on. The default context will use system installed certificate
86-
authority trust chains, if available.
80+
TLS parameters are controlled by passing a ``ssl.SSLContext`` when
81+
creating an IMAPClient instance (or to the `starttls` method when the
82+
STARTTLS is used). When ``ssl=True`` is used without passing a
83+
SSLContext, a default context is used. The default context avoids the
84+
use of known insecure ciphers and SSL protocol versions, with
85+
certificate verification and hostname verification turned on. The
86+
default context will use system installed certificate authority trust
87+
chains, if available.
8788

8889
When constructing a custom context it is usually best to start with
8990
the default context, created by the ``ssl`` module, and modify it to
@@ -109,7 +110,7 @@ certificate used by the IMAP server.
109110

110111
If your operating system comes with an outdated list of CA certificates you can
111112
use the `certifi <https://pypi.python.org/pypi/certifi>`_ package that provides
112-
a list of common and respectable CAs::
113+
an up-to-date set of trusted CAs::
113114

114115
import certifi
115116

@@ -121,11 +122,11 @@ the Python 3 :py:mod:`ssl` package documentation for further options.
121122

122123
Logging
123124
~~~~~~~
124-
IMAPClient logs debug lines using the standard Python `logging module
125-
<https://docs.python.org/3/library/logging.html>`_. Its logger is
126-
``imapclient.*``.
125+
IMAPClient logs debug lines using the standard Python :py:mod:`logging`
126+
module. Its logger prefix is ``imapclient.``.
127127

128-
A simple way to display log messages is to setup logging::
128+
One way to see debug messages from IMAPClient is to set up logging
129+
like this::
129130

130131
import logging
131132

@@ -134,4 +135,5 @@ A simple way to display log messages is to setup logging::
134135
level=logging.DEBUG
135136
)
136137

137-
For advanced usage please refer to the Python documentation.
138+
For advanced usage, please refer to the documentation ``logging``
139+
module.

doc/src/index.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ messages in the INBOX folder.
6969
>>> print('ID #%d: "%s" received %s' % (msgid, envelope.subject.decode(), envelope.date))
7070
ID #62: "Our holidays photos" received 2017-07-20 21:47:42
7171
ID #55: "Re: did you book the hotel?" received 2017-06-26 10:38:09
72-
ID #53: "Re: did you book the holel?" received 2017-06-25 22:02:58
72+
ID #53: "Re: did you book the hotel?" received 2017-06-25 22:02:58
7373
ID #44: "See that fun article about lobsters in Pacific ocean!" received 2017-06-09 09:49:47
7474
ID #46: "Planning for our next vacations" received 2017-05-12 10:29:30
7575

@@ -85,7 +85,6 @@ help you start.
8585
:maxdepth: 2
8686

8787
installation
88-
quickstart
8988
concepts
9089
advanced
9190

doc/src/quickstart.rst

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)