From 0e33f77303261e0c7c51ceae9109794829e226ae Mon Sep 17 00:00:00 2001 From: Bryce Boe Date: Wed, 19 Apr 2017 21:35:51 -0700 Subject: [PATCH] Fix docstring detected as not using imperative mood --- praw/models/listing/mixins/redditor.py | 4 ++-- praw/models/listing/mixins/subreddit.py | 2 +- praw/models/reddit/comment.py | 4 ++-- praw/models/reddit/live.py | 6 +++--- praw/models/reddit/submission.py | 6 +++--- praw/models/reddit/subreddit.py | 24 ++++++++++++------------ praw/models/reddit/wikipage.py | 2 +- 7 files changed, 24 insertions(+), 24 deletions(-) diff --git a/praw/models/listing/mixins/redditor.py b/praw/models/listing/mixins/redditor.py index 0be84041a..1a0ca1046 100644 --- a/praw/models/listing/mixins/redditor.py +++ b/praw/models/listing/mixins/redditor.py @@ -10,7 +10,7 @@ class RedditorListingMixin(BaseListingMixin, GildedListingMixin): @property def comments(self): - r"""An instance of :class:`.SubListing` providing access to comments. + r"""Provide an instance of :class:`.SubListing` for comment access. For example, to output the first line of all new comments by ``/u/spez`` try: @@ -27,7 +27,7 @@ def comments(self): @property def submissions(self): - """An instance of :class:`.SubListing` providing access to submissions. + """Provide an instance of :class:`.SubListing` for submission access. For example, to output the title's of top 100 of all time submissions for ``/u/spez`` try: diff --git a/praw/models/listing/mixins/subreddit.py b/praw/models/listing/mixins/subreddit.py index d3c93fcb6..ad921e0d2 100644 --- a/praw/models/listing/mixins/subreddit.py +++ b/praw/models/listing/mixins/subreddit.py @@ -12,7 +12,7 @@ class SubredditListingMixin(BaseListingMixin, GildedListingMixin, @property def comments(self): - """An instance of :class:`.CommentHelper`. + """Provide an instance of :class:`.CommentHelper`. For example, to output the author of the 25 most recent comments of ``/r/redditdev`` execute: diff --git a/praw/models/reddit/comment.py b/praw/models/reddit/comment.py index 51d9098bc..389ce386b 100644 --- a/praw/models/reddit/comment.py +++ b/praw/models/reddit/comment.py @@ -20,14 +20,14 @@ def is_root(self): @property def mod(self): - """An instance of :class:`.CommentModeration`.""" + """Provide an instance of :class:`.CommentModeration`.""" if self._mod is None: self._mod = CommentModeration(self) return self._mod @property def replies(self): - """An instance of :class:`.CommentForest`.""" + """Provide an instance of :class:`.CommentForest`.""" if isinstance(self._replies, list): self._replies = CommentForest(self.submission, self._replies) return self._replies diff --git a/praw/models/reddit/live.py b/praw/models/reddit/live.py index 889c37958..95f94c4e8 100644 --- a/praw/models/reddit/live.py +++ b/praw/models/reddit/live.py @@ -241,7 +241,7 @@ class LiveThread(RedditBase): @property def contrib(self): - """An instance of :class:`.LiveThreadContribution`. + """Provide an instance of :class:`.LiveThreadContribution`. Usage: @@ -257,7 +257,7 @@ def contrib(self): @property def contributor(self): - """An instance of :class:`.LiveContributorRelationship`. + """Provide an instance of :class:`.LiveContributorRelationship`. You can call the instance to get a list of contributors which is represented as :class:`.RedditorList` instance consists of @@ -525,7 +525,7 @@ class LiveUpdate(RedditBase): @property def contrib(self): - """An instance of :class:`.LiveUpdateContribution`. + """Provide an instance of :class:`.LiveUpdateContribution`. Usage: diff --git a/praw/models/reddit/submission.py b/praw/models/reddit/submission.py index 39d87ca9e..c1a7d8dfb 100644 --- a/praw/models/reddit/submission.py +++ b/praw/models/reddit/submission.py @@ -43,7 +43,7 @@ def id_from_url(url): @property def comments(self): - """An instance of :class:`.CommentForest`. + """Provide an instance of :class:`.CommentForest`. This attribute can use used, for example, to obtain a flat list of comments, with any :class:`.MoreComments` removed: @@ -71,7 +71,7 @@ def comments(self): @property def flair(self): - """An instance of :class:`.SubmissionFlair`. + """Provide an instance of :class:`.SubmissionFlair`. This attribute is used to work with flair as a regular user of the subreddit the submission belongs to. Moderators can directly use @@ -94,7 +94,7 @@ def flair(self): @property def mod(self): - """An instance of :class:`.SubmissionModeration`.""" + """Provide an instance of :class:`.SubmissionModeration`.""" if self._mod is None: self._mod = SubmissionModeration(self) return self._mod diff --git a/praw/models/reddit/subreddit.py b/praw/models/reddit/subreddit.py index 99717509c..c1b334a9f 100644 --- a/praw/models/reddit/subreddit.py +++ b/praw/models/reddit/subreddit.py @@ -119,7 +119,7 @@ def _subreddit_list(subreddit, other_subreddits): @property def banned(self): - """An instance of :class:`.SubredditRelationship`. + """Provide an instance of :class:`.SubredditRelationship`. For example to ban a user try: @@ -141,21 +141,21 @@ def banned(self): @property def contributor(self): - """An instance of :class:`.ContributorRelationship`.""" + """Provide an instance of :class:`.ContributorRelationship`.""" if self._contributor is None: self._contributor = ContributorRelationship(self, 'contributor') return self._contributor @property def filters(self): - """An instance of :class:`.SubredditFilters`.""" + """Provide an instance of :class:`.SubredditFilters`.""" if self._filters is None: self._filters = SubredditFilters(self) return self._filters @property def flair(self): - """An instance of :class:`.SubredditFlair`. + """Provide an instance of :class:`.SubredditFlair`. Provides the interface for interacting with a subreddit's flair. For example to list all the flair for a subreddit which you have the @@ -173,14 +173,14 @@ def flair(self): @property def mod(self): - """An instance of :class:`.SubredditModeration`.""" + """Provide an instance of :class:`.SubredditModeration`.""" if self._mod is None: self._mod = SubredditModeration(self) return self._mod @property def moderator(self): - """An instance of :class:`.ModeratorRelationship`. + """Provide an instance of :class:`.ModeratorRelationship`. For example to add a moderator try: @@ -202,21 +202,21 @@ def moderator(self): @property def modmail(self): - """An instance of :class:`.Modmail`.""" + """Provide an instance of :class:`.Modmail`.""" if self._modmail is None: self._modmail = Modmail(self) return self._modmail @property def muted(self): - """An instance of :class:`.SubredditRelationship`.""" + """Provide an instance of :class:`.SubredditRelationship`.""" if self._muted is None: self._muted = SubredditRelationship(self, 'muted') return self._muted @property def quaran(self): - """An instance of :class:`.SubredditQuarantine`. + """Provide an instance of :class:`.SubredditQuarantine`. This property is named ``quaran`` because ``quarantine`` is a Subreddit attribute returned by Reddit to indicate whether or not a @@ -229,7 +229,7 @@ def quaran(self): @property def stream(self): - """An instance of :class:`.SubredditStream`. + """Provide an instance of :class:`.SubredditStream`. Streams can be used to indefinitely retrieve new comments made to a subreddit, like: @@ -255,14 +255,14 @@ def stream(self): @property def stylesheet(self): - """An instance of :class:`.SubredditStylesheet`.""" + """Provide an instance of :class:`.SubredditStylesheet`.""" if self._stylesheet is None: self._stylesheet = SubredditStylesheet(self) return self._stylesheet @property def wiki(self): - """An instance of :class:`.SubredditWiki`. + """Provide an instance of :class:`.SubredditWiki`. This attribute can be used to discover all wikipages for a subreddit: diff --git a/praw/models/reddit/wikipage.py b/praw/models/reddit/wikipage.py index 10bcf9428..0b44e4039 100644 --- a/praw/models/reddit/wikipage.py +++ b/praw/models/reddit/wikipage.py @@ -21,7 +21,7 @@ def _revision_generator(subreddit, url, generator_kwargs): @property def mod(self): - """An instance of :class:`.WikiPageModeration`.""" + """Provide an instance of :class:`.WikiPageModeration`.""" if self._mod is None: self._mod = WikiPageModeration(self) return self._mod