Skip to content

Commit

Permalink
Various doc cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
LilSpazJoekp committed Nov 22, 2021
1 parent a661e14 commit ffea26c
Show file tree
Hide file tree
Showing 22 changed files with 218 additions and 224 deletions.
2 changes: 1 addition & 1 deletion CHANGES.rst
Expand Up @@ -65,7 +65,7 @@ Unreleased
- :meth:`.trusted` to retrieve a :class:`.RedditorList` of trusted users.
- :meth:`.trust` to add a user to the trusted list.
- :meth:`.distrust` to remove a user from the trusted list.
- :class:`.SQLiteTokenManager` (may not work on Windows)
- :class:`.SQLiteTokenManager` (may not work on Windows).

**Changed**

Expand Down
8 changes: 5 additions & 3 deletions docs/getting_started/configuration.rst
Expand Up @@ -23,9 +23,9 @@ Environment variables have the highest priority, followed by keyword arguments t
Using an HTTP or HTTPS proxy with PRAW
--------------------------------------

PRAW internally relies upon the `requests <https://requests.readthedocs.io/>`_ package
to handle HTTP requests. Requests supports use of ``HTTP_PROXY`` and ``HTTPS_PROXY``
environment variables in order to proxy HTTP and HTTPS requests respectively [`ref
PRAW internally relies upon the requests_ package to handle HTTP requests. Requests
supports use of ``HTTP_PROXY`` and ``HTTPS_PROXY`` environment variables in order to
proxy HTTP and HTTPS requests respectively [`ref
<https://requests.readthedocs.io/en/master/user/advanced/#proxies>`_].

Given that PRAW exclusively communicates with Reddit via HTTPS, only the ``HTTPS_PROXY``
Expand Down Expand Up @@ -73,3 +73,5 @@ The code above creates a Session and `configures it to use a custom certificate
passes it as a parameter when creating the :class:`.Reddit` instance. Note that the
example above uses a :ref:`password_flow` authentication type, but this method will work
for any authentication type.

.. _requests: https://requests.readthedocs.io
2 changes: 1 addition & 1 deletion docs/getting_started/configuration/options.rst
Expand Up @@ -82,7 +82,7 @@ These are options that do not belong in another category, but still play a part

:check_for_async: When ``true``, check if PRAW is being ran in an asynchronous
environment whenever a request is made. If so, a warning will be logged recommending
the usage of `Async PRAW <https://asyncpraw.readthedocs.io/>`_. (default: ``true``)
the usage of `Async PRAW <https://asyncpraw.readthedocs.io/>`_ (default: ``true``).
:ratelimit_seconds: Controls the maximum number of seconds PRAW will capture ratelimits
returned in JSON data. Because this can be as high as 14 minutes, only ratelimits of
up to 5 seconds are captured and waited on by default.
Expand Down
2 changes: 1 addition & 1 deletion docs/package_info/praw7_migration.rst
Expand Up @@ -28,7 +28,7 @@ list. In the example code below, observe how attributes are accessed.
except APIException as exception:
print(exception.error_type)
This can generally be changed to
This can generally be changed to:

.. code-block:: python
Expand Down
2 changes: 1 addition & 1 deletion praw/__init__.py
Expand Up @@ -5,7 +5,7 @@
designed to follow all of Reddit's API rules. You have to give a useragent, everything
else is handled by PRAW so you needn't worry about violating them.
More information about PRAW can be found at https://github.com/praw-dev/praw
More information about PRAW can be found at https://github.com/praw-dev/praw.
"""

Expand Down
2 changes: 1 addition & 1 deletion praw/exceptions.py
Expand Up @@ -211,7 +211,7 @@ def __init__(self, url: str, message: str = "Invalid URL: {}"):
:param url: The invalid URL.
:param message: The message to display. Must contain a format identifier (``{}``
or ``{0}``). (default: ``"Invalid URL: {}"``)
or ``{0}``) (default: ``"Invalid URL: {}"``).
"""
super().__init__(message.format(url))
Expand Down
2 changes: 1 addition & 1 deletion praw/models/comment_forest.py
Expand Up @@ -121,7 +121,7 @@ def replace_more(
:param threshold: The minimum number of children comments a
:class:`.MoreComments` instance must have in order to be replaced.
:class:`.MoreComments` instances that represent "continue this thread" links
unfortunately appear to have 0 children. (default: ``0``).
unfortunately appear to have 0 children (default: ``0``).
:returns: A list of :class:`.MoreComments` instances that were not replaced.
Expand Down
39 changes: 19 additions & 20 deletions praw/models/helpers.py
Expand Up @@ -197,11 +197,11 @@ def create(
r"""Create a new :class:`.LiveThread`.
:param title: The title of the new :class:`.LiveThread`.
:param description: (Optional) The new :class:`.LiveThread`'s description.
:param nsfw: (boolean) Indicate whether this thread is not safe for work
(default: ``False``).
:param resources: (Optional) Markdown formatted information that is useful for
the :class:`.LiveThread`.
:param description: The new :class:`.LiveThread`'s description.
:param nsfw: Indicate whether this thread is not safe for work (default:
``False``).
:param resources: Markdown formatted information that is useful for the
:class:`.LiveThread`.
:returns: The new :class`.LiveThread` object.
Expand Down Expand Up @@ -262,21 +262,20 @@ def create(
:param display_name: The display name for the new multireddit.
:param subreddits: Subreddits to add to the new multireddit.
:param description_md: (Optional) Description for the new multireddit, formatted
in markdown.
:param icon_name: (Optional) Can be one of: ``"art and design"``, ``"ask"``,
``"books"``, ``"business"``, ``"cars"``, ``"comics"``, ``"cute animals"``,
``"diy"``, ``"entertainment"``, ``"food and drink"``, ``"funny"``,
``"games"``, ``"grooming"``, ``"health"``, ``"life advice"``,
``"military"``, ``"models pinup"``, ``"music"``, ``"news"``,
``"philosophy"``, ``"pictures and gifs"``, ``"science"``, ``"shopping"``,
``"sports"``, ``"style"``, ``"tech"``, ``"travel"``, ``"unusual stories"``,
``"video"``, or ``None``.
:param key_color: (Optional) RGB hex color code of the form ``"#FFFFFF"``.
:param visibility: (Optional) Can be one of: ``"hidden"``, ``"private"``,
``"public"`` (default: ``"private"``).
:param weighting_scheme: (Optional) Can be one of: ``"classic"``, ``"fresh"``
(default: ``"classic"``).
:param description_md: Description for the new multireddit, formatted in
markdown.
:param icon_name: Can be one of: ``"art and design"``, ``"ask"``, ``"books"``,
``"business"``, ``"cars"``, ``"comics"``, ``"cute animals"``, ``"diy"``,
``"entertainment"``, ``"food and drink"``, ``"funny"``, ``"games"``,
``"grooming"``, ``"health"``, ``"life advice"``, ``"military"``, ``"models
pinup"``, ``"music"``, ``"news"``, ``"philosophy"``, ``"pictures and
gifs"``, ``"science"``, ``"shopping"``, ``"sports"``, ``"style"``,
``"tech"``, ``"travel"``, ``"unusual stories"``, ``"video"``, or ``None``.
:param key_color: RGB hex color code of the form ``"#FFFFFF"``.
:param visibility: Can be one of: ``"hidden"``, ``"private"``, ``"public"``
(default: ``"private"``).
:param weighting_scheme: Can be one of: ``"classic"``, ``"fresh"`` (default:
``"classic"``).
:returns: The new :class:`.Multireddit` object.
Expand Down
4 changes: 2 additions & 2 deletions praw/models/listing/generator.py
Expand Up @@ -15,9 +15,9 @@ class ListingGenerator(PRAWBase, Iterator):
.. warning::
This class should not be directly utilized. Instead you will find a number of
methods that return instances of the class:
methods that return instances of the class here_.
https://praw.readthedocs.io/en/latest/search.html?q=ListingGenerator
.. _here: https://praw.readthedocs.io/en/latest/search.html?q=ListingGenerator
"""

Expand Down

0 comments on commit ffea26c

Please sign in to comment.