[Pywikipedia-bugs] [Maniphest] [Commented On] T135359: User.isAnonymous() gives wrong result for IP ranges

2016-05-24 Thread Xqt
Xqt added a comment. Yes I agree it is a problem because "user:212.65.1.102/16" may be a valid subpage of "user:212.65.1.102" and is not a range. On the other hand we need some sort of tools to handle IP ranges coming from log entries which acts like a user for some methods. No idea yet.

[Pywikipedia-bugs] [Maniphest] [Commented On] T130911: redirect.py fails for RuntimeError

2016-05-24 Thread jayvdb
jayvdb added a comment. https://ar.wikipedia.org/w/api.php?action=query=querypage=BrokenRedirects=100=info currently contains "2683712": { "pageid": 2683712, "ns": 105, "title": ":\u0623\u0635\u0648\u0627\u062a

[Pywikipedia-bugs] [Maniphest] [Commented On] T115428: imageharvest and panoramiopicker uses BeautifulSoup version 3 instead of bs4

2016-05-24 Thread jayvdb
jayvdb added a comment. nose is expecting `imageharvest -help` to fail. In script_tests, TestScriptHelp has `_expected_failures = failed_dep_script_list` , so the only expected failures are the items in `failed_dep_script_list` . Previously the script failed because the

[Pywikipedia-bugs] [Maniphest] [Commented On] T130911: redirect.py fails for RuntimeError

2016-05-24 Thread jayvdb
jayvdb added a comment. After that, calling `site.loadpageinfo(page)` changes `page._isredir` to False Just noting there is a hack in `APISite.page_isredirect` intended to help with a similar type of problem. https://gerrit.wikimedia.org/r/#/c/101784/ That means page._isredir is being

[Pywikipedia-bugs] [Maniphest] [Commented On] T115428: imageharvest and panoramiopicker uses BeautifulSoup version 3 instead of bs4

2016-05-24 Thread darthbhyrava
darthbhyrava added a comment. New set of errors: FAIL: Test running imageharvest -help. -- _UnexpectedSuccess: >> begin captured logging << vcr.cassette:

[Pywikipedia-bugs] [Maniphest] [Commented On] T130911: redirect.py fails for RuntimeError

2016-05-24 Thread jayvdb
jayvdb added a comment. I can reproduce the problem with site = pywikibot.Site('ar', 'wikipedia') for page in site.broken_redirects(): if page.isRedirectPage(): try: redir = site.getredirtarget(page) except Exception as e:

[Pywikipedia-bugs] [Maniphest] [Edited] T56684: AttributeError: 'Page' object has no attribute '_isredir'

2016-05-24 Thread jayvdb
jayvdb edited the task description. TASK DETAIL https://phabricator.wikimedia.org/T56684 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: jayvdb Cc: Xqt, Sn1per, pywikibot-bugs-list, Mdupont, jayvdb ___

[Pywikipedia-bugs] [Maniphest] [Retitled] T135364: User.send_email fails with TypeError when raising NotEmailableError

2016-05-24 Thread jayvdb
jayvdb changed the title from "raising NotEmailableError in User.send_email fails" to "User.send_email fails with TypeError when raising NotEmailableError". TASK DETAIL https://phabricator.wikimedia.org/T135364 EMAIL PREFERENCES

[Pywikipedia-bugs] [Maniphest] [Edited] T135364: raising NotEmailableError in User.send_email fails

2016-05-24 Thread jayvdb
jayvdb edited the task description. TASK DETAIL https://phabricator.wikimedia.org/T135364 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Xqt, jayvdb Cc: gerritbot, Aklapper, Zppix, Xqt, pywikibot-bugs-list, Lewizho99, Mdupont, Maathavan, jayvdb

[Pywikipedia-bugs] [Maniphest] [Commented On] T135359: User.isAnonymous() gives wrong result for IP ranges

2016-05-24 Thread jayvdb
jayvdb added a comment. I suspect that you're calling this a bug because some log entries types have IP ranges, but the bug is that logentries.py creates a User class for them. A `page.User` object is a subclass of `page.Page` (with an implicit User: namespace), so it only reasonable if it

[Pywikipedia-bugs] [Maniphest] [Updated] T135331: pagegenerators.PreloadingGenerator should be disabled for -liverecentchanges

2016-05-24 Thread jayvdb
jayvdb added a comment. For the general problem wrt in `PreloadingGenerator`, using `groupsize=1` solves the problem. Pages will be emitted immediately. This was previously called `step`, but was renamed in https://phabricator.wikimedia.org/rPWBC65b75413be0168b73a4576c2de94d1ad58a1dc9c.

[Pywikipedia-bugs] [Maniphest] [Commented On] T135505: logentries.LogEntryFactory creates invalid LogEntry type

2016-05-24 Thread jayvdb
jayvdb added a comment. MediaWiki has lots of log types that we dont have specialised classes for, and new log types are created regularly. We must have a fallback class which holds the basic log entry data . Currently it is `LogEntry`, but it could be a special subclass like

[Pywikipedia-bugs] [Maniphest] [Commented On] T135965: IRCBot fails sometimes to detect bot edits in enwiki

2016-05-24 Thread eranroz
eranroz added a comment. I'm using pywikibot core The code that use it: https://github.com/valhallasw/plagiabot/blob/master/IRCRCListener.py [it has a backup implementation of using streams rather than IRC, but I found it is less reliable for long connections] TASK DETAIL

[Pywikipedia-bugs] [Maniphest] [Commented On] T136074: pytest_attrib in dev-requirements.txt doesnt install, breaking Travis and Appveyor CI

2016-05-24 Thread AbdealiJK
AbdealiJK added a comment. This should now be fixed upstream. Here is the pywikibot-core travis build where it works https://travis-ci.org/AbdealiJK/pywikibot-core/builds/132529623 I've tested it on pytest-attrib's appveyor -

[Pywikipedia-bugs] [Maniphest] [Changed Project Column] T136074: pytest_attrib in dev-requirements.txt doesnt install, breaking Travis and Appveyor CI

2016-05-24 Thread jayvdb
jayvdb moved this task from Backlog to Patch merged upstream on the Upstream board. TASK DETAIL https://phabricator.wikimedia.org/T136074 WORKBOARD https://phabricator.wikimedia.org/project/board/153/ EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/

[Pywikipedia-bugs] [Maniphest] [Changed Project Column] T124007: FTP support for reflinks.py

2016-05-24 Thread jayvdb
jayvdb moved this task from Backlog to Patch proposed upstream on the Upstream board. TASK DETAIL https://phabricator.wikimedia.org/T124007 WORKBOARD https://phabricator.wikimedia.org/project/board/153/ EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/

[Pywikipedia-bugs] [Maniphest] [Created] T136074: pytest_attrib in dev-requirements.txt doesnt install, breaking Travis and Appveyor CI

2016-05-24 Thread jayvdb
jayvdb created this task. Herald added subscribers: pywikibot-bugs-list, Zppix, Aklapper. TASK DESCRIPTION https://github.com/AbdealiJK/pytest-attrib/issues/5 TASK DETAIL https://phabricator.wikimedia.org/T136074 EMAIL PREFERENCES

[Pywikipedia-bugs] [Maniphest] [Updated] T135409: Implement pywikibot support for adding thanks to normal revisions

2016-05-24 Thread darthbhyrava
darthbhyrava added a comment. As per https://phabricator.wikimedia.org/T135933, my method in `thanks.py` for this should take a revision object as argument, and then use the thank API to thank the rev as a bot. After looking at `flow.py`, `flow_tests.py`, `page.py` and `site.py` to see how