jenkins-bot has submitted this change and it was merged. (
https://gerrit.wikimedia.org/r/350846 )
Change subject: [doc] use epydoc for parameter description
......................................................................
[doc] use epydoc for parameter description
Change-Id: Iabf811a277ec41274353b7957e3eb127792a65a8
---
M scripts/claimit.py
M scripts/harvest_template.py
M scripts/replace.py
M scripts/template.py
4 files changed, 28 insertions(+), 23 deletions(-)
Approvals:
Dalba: Looks good to me, approved
jenkins-bot: Verified
diff --git a/scripts/claimit.py b/scripts/claimit.py
index 19142df..bf1edc3 100755
--- a/scripts/claimit.py
+++ b/scripts/claimit.py
@@ -77,11 +77,12 @@
"""
Constructor.
- Arguments:
- * generator - A generator that yields Page objects.
- * claims - A list of wikidata claims
- * exists_arg - String specifying how to handle duplicate claims
-
+ @param generator: A generator that yields Page objects.
+ @type generator: iterator
+ @param claims: A list of wikidata claims
+ @type claims: list
+ @param exists_arg: String specifying how to handle duplicate claims
+ @type exists_arg: str
"""
self.availableOptions['always'] = True
super(ClaimRobot, self).__init__(use_from_page=None)
diff --git a/scripts/harvest_template.py b/scripts/harvest_template.py
index 309705e..dfe413d 100755
--- a/scripts/harvest_template.py
+++ b/scripts/harvest_template.py
@@ -65,11 +65,12 @@
"""
Constructor.
- Arguments:
- * generator - A generator that yields Page objects.
- * templateTitle - The template to work on
- * fields - A dictionary of fields that are of use to us
-
+ @param generator: A generator that yields Page objects
+ @type generator: iterator
+ @param templateTitle: The template to work on
+ @type templateTitle: str
+ @param fields: A dictionary of fields that are of use to us
+ @type fields: dict
"""
self.availableOptions['always'] = True
super(HarvestRobot, self).__init__()
diff --git a/scripts/replace.py b/scripts/replace.py
index f235c95..1328baa 100755
--- a/scripts/replace.py
+++ b/scripts/replace.py
@@ -403,15 +403,17 @@
Iterator that will yield Pages that might contain text to replace.
These pages will be retrieved from a local XML dump file.
- Arguments:
- * xmlFilename - The dump's path, either absolute or relative
- * xmlStart - Skip all articles in the dump before this one
- * replacements - A list of 2-tuples of original text (as a
- compiled regular expression) and replacement
- text (as a string).
- * exceptions - A dictionary which defines when to ignore an
- occurrence. See docu of the ReplaceRobot
- constructor below.
+
+ @param xmlFilename: The dump's path, either absolute or relative
+ @type xmlFilename: str
+ @param xmlStart: Skip all articles in the dump before this one
+ @type xmlStart: str
+ @param replacements: A list of 2-tuples of original text (as a
+ compiled regular expression) and replacement text (as a string).
+ @type replacements: list of 2-tuples
+ @param exceptions: A dictionary which defines when to ignore an
+ occurrence. See docu of the ReplaceRobot constructor below.
+ @type exceptions: dict
"""
def __init__(self, xmlFilename, xmlStart, replacements, exceptions, site):
diff --git a/scripts/template.py b/scripts/template.py
index b4bd2aa..76df5ac 100755
--- a/scripts/template.py
+++ b/scripts/template.py
@@ -144,10 +144,11 @@
"""
Constructor.
- Arguments:
- * templateNames - A list of Page object representing the searched
- templates
- * xmlfilename - The dump's path, either absolute or relative
+ @param templateNames: A list of Page objects representing the searched
+ templates
+ @type templateNames: list
+ @param xmlfilename: The dump's path, either absolute or relative
+ @type xmlfilename: str
"""
self.templates = templates
--
To view, visit
https://gerrit.wikimedia.org/r/350846
To unsubscribe, visit
https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Iabf811a277ec41274353b7957e3eb127792a65a8
Gerrit-PatchSet: 2
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Xqt <info(a)gno.de>
Gerrit-Reviewer: Dalba <dalba.wiki(a)gmail.com>
Gerrit-Reviewer: Magul <tomasz.magulski(a)gmail.com>
Gerrit-Reviewer: Xqt <info(a)gno.de>
Gerrit-Reviewer: jenkins-bot <>