Zoranzoki21 has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/395094 )
Change subject: Disable needing text file for running reflinks.py script
......................................................................
Disable needing text file for running reflinks.py script
Bug: T182021
Change-Id: Ie0e98a2ef9f8abad596c7ef55c9b53bce6278c2a
---
M scripts/reflinks.py
1 file changed, 0 insertions(+), 13 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/pywikibot/core
refs/changes/94/395094/1
diff --git a/scripts/reflinks.py b/scripts/reflinks.py
index 6553876..acb9a4d 100755
--- a/scripts/reflinks.py
+++ b/scripts/reflinks.py
@@ -179,11 +179,6 @@
# unbracketed without ()
r'[^\[\]\s<>"]+[^\[\]\s\)\.:;\\,<>\?"]+|[^\[\]\s<>"]+))[!?,\s]*\]?\s*</ref>')
-# Download this file :
-# http://www.twoevils.org/files/wikipedia/404-links.txt.gz
-# ( maintained by User:Dispenser )
-listof404pages = '404-links.txt'
-
XmlDumpPageGenerator = partial(
_XMLDumpPageGenerator, text_predicate=linksInRef.search)
@@ -487,14 +482,6 @@
def run(self):
"""Run the Bot."""
- try:
- deadLinks = codecs.open(listof404pages, 'r', 'latin_1').read()
- except IOError:
- raise NotImplementedError(
- '404-links.txt is required for reflinks.py\n'
- 'You need to download\n'
- 'http://www.twoevils.org/files/wikipedia/404-links.txt.gz\n'
- 'and to unzip it in the same directory')
editedpages = 0
for page in self.generator:
--
To view, visit https://gerrit.wikimedia.org/r/395094
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie0e98a2ef9f8abad596c7ef55c9b53bce6278c2a
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Owner: Zoranzoki21 <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits