https://bugzilla.wikimedia.org/show_bug.cgi?id=72209
Bug ID: 72209
Summary: testExturlusage takes forever on test.wikipedia
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: tests
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
testExturlusage uses:
for link in mysite.exturlusage('www.google.com', namespaces=[2, 3],
total=5)
This returns quickly on test.wikidata , as there is very little data that
matches
https://test.wikidata.org/w/index.php?title=Special%3ALinkSearch&target=htt…
All of the other travis build platforms also provide the five records requested
in a reasonable period of time.
While test.wikipedia has a lot of data that matches:
https://test.wikipedia.org/w/index.php?title=Special%3ALinkSearch&target=ht…
PageGenerator on test.wikipedia yields four results after a few API calls,
however after the fourth result it has backed off to requesting data with a
geulimit of 1, resulting in the following data request/results sequence:
{'inprop': [u'protection'], 'geuprotocol': [u'http'], 'iiprop': [u'timestamp',
u'user', u'comment', u'url', u'size', u'sha1', u'metadata'], 'maxlag': ['5'],
u'geuoffset': [u'20'], 'generator': [u'exturlusage'], 'format': ['json'],
'prop': [u'info', u'imageinfo', u'categoryinfo'], 'meta': ['userinfo'],
'indexpageids': [u''], u'geulimit': [u'1'], 'action': [u'query'],
u'geunamespace': [u'2', u'3'], 'geuquery': [u'www.google.com'], 'uiprop':
['blockinfo', 'hasmsg']}
{u'query-continue': {u'exturlusage': {u'geuoffset': 21}}, u'query':
{u'userinfo': {u'messages': u'', u'id': 25377, u'name': u'JVbot'}}}
{'inprop': [u'protection'], 'geuprotocol': [u'http'], 'iiprop': [u'timestamp',
u'user', u'comment', u'url', u'size', u'sha1', u'metadata'], 'maxlag': ['5'],
u'geuoffset': [u'21'], 'generator': [u'exturlusage'], 'format': ['json'],
'prop': [u'info', u'imageinfo', u'categoryinfo'], 'meta': ['userinfo'],
'indexpageids': [u''], u'geulimit': [u'1'], 'action': [u'query'],
u'geunamespace': [u'2', u'3'], 'geuquery': [u'www.google.com'], 'uiprop':
['blockinfo', 'hasmsg']}
{u'query-continue': {u'exturlusage': {u'geuoffset': 22}}, u'query':
{u'userinfo': {u'messages': u'', u'id': 25377, u'name': u'JVbot'}}}
{'inprop': [u'protection'], 'geuprotocol': [u'http'], 'iiprop': [u'timestamp',
u'user', u'comment', u'url', u'size', u'sha1', u'metadata'], 'maxlag': ['5'],
u'geuoffset': [u'22'], 'generator': [u'exturlusage'], 'format': ['json'],
'prop': [u'info', u'imageinfo', u'categoryinfo'], 'meta': ['userinfo'],
'indexpageids': [u''], u'geulimit': [u'1'], 'action': [u'query'],
u'geunamespace': [u'2', u'3'], 'geuquery': [u'www.google.com'], 'uiprop':
['blockinfo', 'hasmsg']}
{u'query-continue': {u'exturlusage': {u'geuoffset': 23}}, u'query':
{u'userinfo': {u'messages': u'', u'id': 25377, u'name': u'JVbot'}}}
{'inprop': [u'protection'], 'geuprotocol': [u'http'], 'iiprop': [u'timestamp',
u'user', u'comment', u'url', u'size', u'sha1', u'metadata'], 'maxlag': ['5'],
u'geuoffset': [u'23'], 'generator': [u'exturlusage'], 'format': ['json'],
'prop': [u'info', u'imageinfo', u'categoryinfo'], 'meta': ['userinfo'],
'indexpageids': [u''], u'geulimit': [u'1'], 'action': [u'query'],
u'geunamespace': [u'2', u'3'], 'geuquery': [u'www.google.com'], 'uiprop':
['blockinfo', 'hasmsg']}
{u'query-continue': {u'exturlusage': {u'geuoffset': 24}}, u'query':
{u'userinfo': {u'messages': u'', u'id': 25377, u'name': u'JVbot'}}}
It then proceeds to iterate continuously seemingly forever. (I killed it after
10 mins)
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=64877
Bug ID: 64877
Summary: Add cross-wiki Special:Import support
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: valhallasw(a)arctus.nl
Blocks: 55880
Web browser: ---
Mobile Platform: ---
See action=import on https://nl.wikipedia.org/w/api.php and pageimport.py on
compat
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=64878
Bug ID: 64878
Summary: Port parserfunctioncount.py to core
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: valhallasw(a)arctus.nl
Blocks: 55880
Web browser: ---
Mobile Platform: ---
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=64159
Bug ID: 64159
Summary: Port tag_nowcommons.py to Pywikibot core
Product: Pywikibot
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: mian(a)tdcadsl.dk
Web browser: ---
Mobile Platform: ---
I used tag_nowcommons.py a lot in the past but I can't get it to work anymore
(I have been trying on labs lately). As I understand it the reason is probably
because it should be updated and ported to core.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=69476
Bug ID: 69476
Summary: Non-ascii path results in UnicodeDecodeError
Product: Pywikibot
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: major
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: aukce59(a)gmail.com
Web browser: ---
Mobile Platform: ---
when running recent (13.8.2014) core pywikibot through pwb.py I get this error:
Traceback (most recent call last):
File "pwb.py", line 171, in <module>
run_python_file(fn, argv, argvu)
File "pwb.py", line 69, in run_python_file
exec(compile(source, filename, "exec"), main_mod.__dict__)
File "scripts\login.py", line 116, in <module>
main()
File "scripts\login.py", line 69, in main
for arg in pywikibot.handleArgs(*args):
File "C:\Users\JonßÜ\Desktop\Jonas\core\pywikibot\bot.py", line 663, in
handleArgs
init_handlers()
File "C:\Users\JonßÜ\Desktop\Jonas\core\pywikibot\bot.py", line 245, in
init_handlers
writelogheader()
File "C:\Users\JonßÜ\Desktop\Jonas\core\pywikibot\bot.py", line 303, in
writelogheader
log(u' %(name)s (%(path)s) = %(ver)s' % info)
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe1 in position 12:
ordinal not in range(128)
<type 'exceptions.UnicodeDecodeError'>
CRITICAL: Waiting for 1 network thread(s) to finish. Press ctrl-c to abort
the path is "....Users\Jonáš\Desktop....". Using bot placed in ascii-only
characters path solves the issue.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72249
Bug ID: 72249
Summary: py34 pwb.py loads externals/httplib2 even if it is
empty
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
Normally if the externals/httplib2 directory is empty, and there is no httplib2
installed on the system, running pwb.py will report an error and advise the
user to use git recursive to install httplib2 into the externals directory.
Python 3.4 (and 3.5 nightlys) will 'import' the directory externals/httplib2
even when it is empty, causing pwb.py to fail when it attempts to access
'httplib2.__version__' which doesnt exist in the empty directory
externals/httplib2.
Steps to reproduce:
1. Uninstall httplib2 from python34 environment.
2. rm -rf externals/httplib2
3. mkdir externals/httplib2
4. python34 pwb.py version
Expected results:
An error like:
Python module httplib2 >= 0.6.0 is required.
Did you clone without --recursive?
Try running 'git submodule update --init'
Actual results:
AttributeError: 'module' object has no attribute '__version__'
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72227
Bug ID: 72227
Summary: All doctests fail
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: major
Priority: Unprioritized
Component: tests
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
There are doctests in
* pywikibot.comms.threadedhttp.HttpRequest
* pywikibot.data.api.Request
* pywikibot.tools.itergroup
* pywikibot.i18n.twntranslate
They all fail, for various reasons. See
$ nosetests --with-doctest -v pywikibot
...
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72127
Bug ID: 72127
Summary: MySQLPageGenerator syntax error
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
MySQLPageGenerator tries to compare 'site' against pywikibot.site.Site,
which doesnt exist. Bug introduced in Aug 2013 (git 2e35403), and
pywikibot.site.Site didnt exist then either.
Welcome to the Pywikibot interactive shell!
>>> import pywikibot.pagegenerators
>>> gen = pywikibot.pagegenerators.MySQLPageGenerator('SELECT * FROM DUAL')
>>> p = next(gen)
Traceback (most recent call last):
File "<console>", line 1, in <module>
File ".../pywikibot/pagegenerators.py", line 1451, in MySQLPageGenerator
if isinstance(site, pywikibot.site.Site):
AttributeError: 'module' object has no attribute 'Site'
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72238
Bug ID: 72238
Summary: site.logged_in() returns False when logged in to sysop
account
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: Linux
Status: NEW
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: codecat42(a)gmail.com
Web browser: ---
Mobile Platform: ---
My user-config.py contains:
usernames['wiktionary']['en'] = u'MewBot'
sysopnames['wiktionary']['en'] = u'CodeCat'
So when I perform an action that requires sysop access, it should switch to
another account, and indeed it does. It asks me to log in to the sysop account.
But once logged in, and then attempting to delete a page, the following occurs:
Traceback (most recent call last):
File "Desktop/bot/deleteempty.py", line 13, in <module>
current.delete(reason="Empty category; recreate when needed", prompt=False)
File "(redacted)/pywikibot/pywikibot/tools.py", line 529, in wrapper
return obj(*__args, **__kw)
File "(redacted)/pywikibot/pywikibot/page.py", line 1489, in delete
return self.site.deletepage(self, reason)
File "(redacted)/pywikibot/pywikibot/site.py", line 932, in callee
return fn(self, *args, **kwargs)
File "(redacted)/pywikibot/pywikibot/site.py", line 4033, in deletepage
token = self.tokens['delete']
File "(redacted)/pywikibot/pywikibot/site.py", line 1279, in __getitem__
assert(self.site.logged_in())
AssertionError
<type 'exceptions.AssertionError'>
I inserted some test code into site.py to see why the assertion is failing. And
curiously, self.site.logged_in() returns False, but
self.site.logged_in(sysop=True) returns True. Tracking it down further to the
logged_in method, it appears that the condition
if self.userinfo['name'] != self._username[sysop]:
return False
is what is returning False. Inserting a test to display the two values being
compared, it turns out that self.userinfo['name'] is the sysop user name, but
self._username[sysop] is the regular user name. This is not terribly surprising
as sysop is False in this case.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72244
Bug ID: 72244
Summary: RandomPageGenerator always reurns 10 pages
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: mpaa.wiki(a)gmail.com
Web browser: ---
Mobile Platform: ---
>>> python scripts/listpages.py -random:15
1 Ajjamma
2 Muthukumarcyz
3 Cite pmid/9770300
4 93.109.68.75
5
Ganeshbot/Animalia/Gastropoda/Caenogastropoda/Neogastropoda/Conoidea/Raphitomidae/Bathybela
6 Trebor Mai.jpg
7 98.28.188.199
8 1942 in Algeria
9 14.201.56.55
10 Articles for deletion/List of WWE '12 characters (2nd nomination)
--
You are receiving this mail because:
You are the assignee for the bug.