https://bugzilla.wikimedia.org/show_bug.cgi?id=64489
Bug ID: 64489
Summary: Clean up limit handling (data/api.py)
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: 56190
Web browser: ---
Mobile Platform: ---
QueryGenerator has a very complicated structure to handle request limit
handling; some of it is currently working by accident, e.g.:
new_limit = None
(...)
new_limit = min(new_limit, self.api_limit // 10, 250)
Now, new_limit is what? None!
(at least, on python 2 -- this returns an error in python 3)
Which is actually required as some requests don't allow limits, such as
https://en.wikipedia.org/w/api.php?maxlag=5&pageids=1969218|225758|38275275…
adding &rvlimit=50 returns
error: {
code: "rvmultpages",
info: "titles, pageids or a generator was used to supply multiple pages, but
the limit, startid, endid, dirNewer, user, excludeuser, start and end
parameters may only be used on a single page."
}
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=62261
Bug ID: 62261
Summary: Throw specific error instead of generic APIError if
claim target is deleted
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: minor
Priority: Unprioritized
Component: Wikidata
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: felix(a)fex-it.de
Web browser: ---
Mobile Platform: ---
If adding a claim, two types of errors are thrown in case of a deleted item:
item = pywikibot.ItemPage(repo, "Q726")
target = pywikibot.ItemPage(repo, "Q14854094")
c = pywikibot.Claim(repo, u'P171')
c.addTarget(target)
item.addClaim(c) # Error if item or target were deleted
At the last line, you get either
pywikibot.exceptions.NoPage: Page [[wikidata:-1]] doesn't exist.
if item (Q726) has been deleted or
pywikibot.data.api.APIError: invalid-snak-value: Q14854094 not found
if the target (Q14854094) has been deleted.
It would be great, if for the latter a specific "InvalidValueError" or similar
would be thrown. Then, the error could be caught and handled specifically
without the need to parse the (possibly changing) API error message itself.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=68705
Bug ID: 68705
Summary: 'category remove' regression when category contains
only files
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: category.py
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
(Creating bug from https://gerrit.wikimedia.org/r/#/c/149645/)
In May 2014 this changeset broke 'category.py remove' for categories with only
files and no pages.
https://gerrit.wikimedia.org/r/#/c/130301/
It is also a significant performance regression as 'categoryinfo' requires the
server to fetch all of the category members, which is slow, only to return
counts, when category.py needs to iterate over the category members, so it must
hit the server again.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=68988
Bug ID: 68988
Summary: watchlist.py should used CachedRequest
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: ---
Bug 57995 adds a new script watchlist.py, ported from core.
The way the watchlist is cached should be upgraded to use CachedRequest.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=69781
Bug ID: 69781
Summary: makecat uses http on import, causing deadlock
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: ---
makecat has its main loop at the module level, rather than in a function main()
like other scripts.
This causes a deadlock in handleArgs while trying to fetch the live API
version.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72236
Bug ID: 72236
Summary: Family.ignore_certificate_error does not work in py3
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: minor
Priority: Unprioritized
Component: network
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
py3 httplib2 (https://github.com/jcgregorio/httplib2/issues/173) has problems
ignoring errors/not validating SSL certificates.
As a result, Family.ignore_certificate_error does not work in py3
File "/usr/lib/python3.3/site-packages/httplib2/__init__.py", line 1156, in
request
self.disable_ssl_certificate_validation)
File "/usr/lib/python3.3/site-packages/httplib2/__init__.py", line 830, in
__init__
check_hostname=True)
File "/usr/lib64/python3.3/http/client.py", line 1183, in __init__
raise ValueError("check_hostname needs a SSL context with "
ValueError: check_hostname needs a SSL context with either CERT_OPTIONAL or
CERT_REQUIRED
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=72503
Bug ID: 72503
Summary: generate_family_file.py fails
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: Phoenixoverride(a)gmail.com
Web browser: ---
Mobile Platform: ---
if generate_family_file.py is invoked via pwb.py generate_family_file.py the
framework doesnt generate a family file
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=71121
Bug ID: 71121
Summary: RepeatingGenerator intermittent failure on
test.wikidata
Product: Pywikibot
Version: core (2.0)
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: pagegenerators
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: jayvdb(a)gmail.com
Web browser: ---
Mobile Platform: ---
We have seen a few intermittent failures of RepeatingGenerator. The most
recent is on test.wikidata:
https://travis-ci.org/wikimedia/pywikibot-core/jobs/35913559
IIRC, the previous ones have also been test.wikidata
My guess is there is insufficient recent change data on this wiki, and a
looping problem is causing infinite looping.
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=71786
Bug ID: 71786
Summary: verbose output on py3 fails
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: ---
Running any command with verbose enabled caused a KeyError
$ python3 pwb.py scripts/basic.py -verbose
The base directory is ...
=== Pywikibot framework v2.0 -- Logging header ===
COMMAND: ['scripts/basic.py', '-verbose']
DATE: 2014-10-08 09:33:57.946123 UTC
VERSION: [ssh] pywikibot-core.git (62c17a3, g4217, 2014/10/07, 19:19:01, n/a)
SYSTEM: posix.uname_result(sysname='Linux', nodename='RSD-Latitude-2120',
release='3.13.0-36-generic', version='#63-Ubuntu SMP Wed Sep 3 21:30:45 UTC
2014', machine='i686')
Traceback (most recent call last):
File "pwb.py", line 164, 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/basic.py", line 173, in <module>
main()
File "scripts/basic.py", line 142, in main
local_args = pywikibot.handleArgs()
File ".../pywikibot/bot.py", line 666, in handleArgs
init_handlers()
File ".../pywikibot/bot.py", line 248, in init_handlers
writelogheader()
File ".../pywikibot/bot.py", line 291, in writelogheader
packages = version.package_versions(check_package_list)
File ".../pywikibot/version.py", line 381, in package_versions
del data[name]
KeyError: '_frozen_importlib'
--
You are receiving this mail because:
You are the assignee for the bug.
https://bugzilla.wikimedia.org/show_bug.cgi?id=55011
Web browser: ---
Bug ID: 55011
Summary: Support for Wikimedia Labs and Toolserver
Product: Pywikibot
Version: unspecified
Hardware: All
OS: All
Status: NEW
Severity: enhancement
Priority: Unprioritized
Component: General
Assignee: Pywikipedia-bugs(a)lists.wikimedia.org
Reporter: legoktm.wikipedia(a)gmail.com
Classification: Unclassified
Mobile Platform: ---
Originally from: http://sourceforge.net/p/pywikipediabot/feature-requests/335/
Reported by: cdpark
Created on: 2013-04-08 01:52:09
Subject: Support for Wikimedia Labs and Toolserver
Original description:
1\. Source directory repositiory
Split pywikipedia source and user config/script. See also
https://wikitech.wikimedia.org/wiki/Nova\_Resource\_Talk:Bots\#Pywikipediab…
Currently, pywikipedia imports\(or includes\) other file from \(1\) source code
directory \(2\) current working directory \(3\) pywikipedia environment,
depends on code. How about to support PYWIKIPEDIA\_HOME or similar environment
for source code repository.
2\. Local mysql mirror support.
In WMLabs and toolserver, access of wikipedia mirror is available. Page.get\(\)
and pagegenerators can be use this information. \(BTW, Page.put\(\) should work
to original site, not mirrors\). It can be also useful for other mediawiki
installs if admin runs some pywikipedia-based script \(e.g. replace.py\) for
his own database.
--
You are receiving this mail because:
You are the assignee for the bug.