Xqt has uploaded a new change for review.
https://gerrit.wikimedia.org/r/286947
Change subject: [IMPR] use http.fetch instead of http.request
......................................................................
[IMPR] use http.fetch instead of http.request
Change-Id: I009b55ac147c4f862387a9eeb19d90aa2ce86687
---
M checkvotes.py
1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/pywikibot/bots/xqbot
refs/changes/47/286947/1
diff --git a/checkvotes.py b/checkvotes.py
index d451d4a..3ab9b7e 100644
--- a/checkvotes.py
+++ b/checkvotes.py
@@ -407,7 +407,7 @@
# check voting rights
try:
- data = http.request(uri=path)
+ data = http.fetch(uri=path)
except KeyboardInterrupt:
return
except:
@@ -418,7 +418,7 @@
R = re.compile(r'>Schiedsgerichtswahl: (.+?)</div>')
else:
R = re.compile(r'>Allgemeine Stimmberechtigung
<.+?>\((?:alt|neu)\)</a>: (.+?)</div>')
- result = R.findall(data)
+ result = R.findall(data.content)
if self.blockinfo: # write blocking info
try:
if user.isBlocked():
--
To view, visit https://gerrit.wikimedia.org/r/286947
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I009b55ac147c4f862387a9eeb19d90aa2ce86687
Gerrit-PatchSet: 1
Gerrit-Project: pywikibot/bots/xqbot
Gerrit-Branch: master
Gerrit-Owner: Xqt <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits