[Pywikipedia-bugs] [Maniphest] [Closed] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-13 Thread Vladis13
Vladis13 closed this task as "Resolved". TASK DETAIL https://phabricator.wikimedia.org/T344086 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: matej_suchanek, Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb, Jyoo1011, Jo

[Pywikipedia-bugs] [Maniphest] [Commented On] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-13 Thread Vladis13
Vladis13 added a comment. The bot made 4 new items, seems to work. I close the issue, reopen if the problem is not solved. Thanks for the answer. Maybe add a note about this argument to the method's declaration and/or `user_edit_entity()`? TASK DETAIL https

[Pywikipedia-bugs] [Maniphest] [Edited] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-12 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T344086 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: matej_suchanek, Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb, Jyoo1011, JohnsonLee01

[Pywikipedia-bugs] [Maniphest] [Commented On] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-12 Thread Vladis13
Vladis13 added a comment. ID is not returned in about 20-30% of cases, as I noticed. TASK DETAIL https://phabricator.wikimedia.org/T344086 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: matej_suchanek, Aklapper, pywikibot-bugs-list

[Pywikipedia-bugs] [Maniphest] [Edited] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-12 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T344086 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: matej_suchanek, Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb, Jyoo1011, JohnsonLee01

[Pywikipedia-bugs] [Maniphest] [Edited] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-11 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T344086 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb, Jyoo1011, JohnsonLee01, SHEKH, Dijkstra

[Pywikipedia-bugs] [Maniphest] [Retitled] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it impossible to add claims to it

2023-08-11 Thread Vladis13
Vladis13 renamed this task from "The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, which makes it impossible to add claims to it" to "The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, making it im

[Pywikipedia-bugs] [Maniphest] [Created] T344086: The WikidataBot.create_item_for_page() method doesn't return the ID of the created item, which makes it impossible to add claims to it

2023-08-11 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION **What happens?**: My bot creates items for wikipages, then claims are added to them. The `WikidataBot.create_item_for_page()` method

[Pywikipedia-bugs] [Maniphest] [Commented On] T318239: scripts/category.py: Allow pagegenerators intersection with actions other than "add"

2022-09-25 Thread Vladis13
Vladis13 added a comment. I have done `git pull`. > pwb.py -simulate category -site:wikisource:ru -cat:"ОУН-УПА" remove -from:"Украина" ERROR: Unknown parameter "-cat:ОУН-УПА". Use -help for further information. Also, a new bug appe

[Pywikipedia-bugs] [Maniphest] [Commented On] T318239: scripts/category.py: Allow pagegenerators intersection with actions other than "add"

2022-09-21 Thread Vladis13
Vladis13 added a comment. How to remove pages from a category by generator? The only way is to use the `remove.py` script with the `-regex` argument? `pwb.py replace -family:wikisource -lang:ru -cat:"OUN-UPA" -regex '\[\[Category:Ukraine\]\]\n?' ''` TASK DETA

[Pywikipedia-bugs] [Maniphest] [Commented On] T318239: scripts/category.py: Allow pagegenerators intersection with actions other than "add"

2022-09-21 Thread Vladis13
Vladis13 added a comment. There is also confusion with the name of the argument. The script (by page generator) execute for each page the `remove -from:category_name` command. In human terms, this means: remove this page from the categoryname category. But it turns out

[Pywikipedia-bugs] [Maniphest] [Commented On] T318239: scripts/category.py: Allow pagegenerators intersection with actions other than "add"

2022-09-21 Thread Vladis13
Vladis13 added a comment. Hm. The `category.py` help at https://doc.wikimedia.org/pywikibot/stable/scripts/main.html#module-scripts.category also says "This script supports use of pywikibot.pagegenerators arguments." TASK DETAIL https://phabricator.wikimedia.org/T318239 EMAIL P

[Pywikipedia-bugs] [Maniphest] [Commented On] T318239: scripts/category.py: Problem with the page generator

2022-09-21 Thread Vladis13
Vladis13 added a comment. All of these scripts are based on `pywikibot.pagegenerators` and `pywikibot.bot`, and use common generator arguments. If this script is somehow strange, could you remove the list of generator commands from the script's help (`pwb.py category -help`) and from its

[Pywikipedia-bugs] [Maniphest] [Commented On] T318236: scripts/category.py: Bug of "-always" argument

2022-09-21 Thread Vladis13
Vladis13 added a comment. How to disable `-always` for other bulk edit commands? TASK DETAIL https://phabricator.wikimedia.org/T318236 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Xqt, Aklapper, pywikibot-bugs-list, Vladis13

[Pywikipedia-bugs] [Maniphest] [Updated] T318236: scripts/category.py: Bug of "-always" argument

2022-09-21 Thread Vladis13
Vladis13 added a comment. I use the `remove` command, examples are given here T318239 <https://phabricator.wikimedia.org/T318239>. TASK DETAIL https://phabricator.wikimedia.org/T318236 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladi

[Pywikipedia-bugs] [Maniphest] [Edited] T318239: scripts/category.py: Problem with the page generator

2022-09-21 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T318239 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb, Jyoo1011, JohnsonLee01, SHEKH, Dijkstra

[Pywikipedia-bugs] [Maniphest] [Edited] T318239: scripts/category.py: Problem with the page generator

2022-09-21 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T318239 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb, Jyoo1011, JohnsonLee01, SHEKH, Dijkstra

[Pywikipedia-bugs] [Maniphest] [Created] T318239: scripts/category.py: Problem with the page generator

2022-09-21 Thread Vladis13
Vladis13 created this task. Vladis13 added projects: Pywikibot, Pywikibot-Scripts. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION I want to remove a category from the intersection list of two other categories using the `-intersect` argument

[Pywikipedia-bugs] [Maniphest] [Updated] T318236: scripts/category.py: Bug of "-always" argument

2022-09-21 Thread Vladis13
Vladis13 edited projects, added Pywikibot-category.py; removed Pywikibot-Scripts. TASK DETAIL https://phabricator.wikimedia.org/T318236 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Aklapper, pywikibot-bugs-list, Vladis13, PotsdamLamb

[Pywikipedia-bugs] [Maniphest] [Created] T318236: scripts/category.py: Bug of "-always" argument

2022-09-21 Thread Vladis13
Vladis13 created this task. Vladis13 added projects: Pywikibot-Scripts, Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION I'm running the `category.py` script without the `-always` argument, so the bot should show the diff and ask if it needs

[Pywikipedia-bugs] [Maniphest] [Created] T307826: movepages.py: arguments recognition error

2022-05-06 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION There is broken the `movepages.py` script, arguments recognition error. Since the 28 March commit (github <https://github.com/wikime

[Pywikipedia-bugs] [Maniphest] [Created] T291757: pagefromfile.py script: Problem of "-force" argument and user_confirm()

2021-09-25 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION **What happens?**: My bot using the `pagefromfile.py` script has stopped working. The script asks for manual confirmation of page

[Pywikipedia-bugs] [Maniphest] [Created] T285027: "add_text,py" error

2021-06-15 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION Since June, the "add_text" script gives an error. My bot is broken. pwb.py add_text -family:wikipedia -lang:r

[Pywikipedia-bugs] [Maniphest] [Commented On] T279753: MySQL: AttributeError: 'Cursor' object has no attribute 'cursor

2021-04-09 Thread Vladis13
Vladis13 added a comment. Thanks you. TASK DETAIL https://phabricator.wikimedia.org/T279753 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Xqt, Vladis13 Cc: JJMC89, Xqt, Aklapper, pywikibot-bugs-list, Vladis13, Jyoo1011, JohnsonLee01, SHEKH

[Pywikipedia-bugs] [Maniphest] [Commented On] T279753: MySQL: AttributeError: 'Cursor' object has no attribute 'cursor

2021-04-09 Thread Vladis13
Vladis13 added a comment. Was Pwb 3.0.dev0 (this version number did not change until this year for several years, although Pwb itself was regularly updated, probably it was a bug) → 6.0.1 PyMySQL 0.9.3 → 1.0.2 Python 3.7. TASK DETAIL https://phabricator.wikimedia.org/T279753 EMAIL

[Pywikipedia-bugs] [Maniphest] [Commented On] T279753: MySQL: AttributeError: 'Cursor' object has no attribute 'cursor

2021-04-08 Thread Vladis13
Vladis13 added a comment. I updated `pywikibot` and `pymysql` and it worked. I think, need to add check for the version of `pymysql` to `pywikibot/data/mysql.py`, and revert the code for support version <1.0.0. Or at least a notification that bots developers need to update `pymysql`. T

[Pywikipedia-bugs] [Maniphest] [Created] T279753: MySQL: AttributeError: 'Cursor' object has no attribute 'cursor

2021-04-08 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION The database queries in my bots, based on Pywikibot, crashes after the March changes (renamed the database replica <ht

[Pywikipedia-bugs] [Maniphest] [Edited] T274723: TypeError: mime param in api.Request() must not be boolean

2021-02-13 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T274723 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Aklapper, pywikibot-bugs-list, Vladis13, Jyoo1011, JohnsonLee01, SHEKH, Dijkstra, Khutuck

[Pywikipedia-bugs] [Maniphest] [Created] T274723: TypeError: mime param in api.Request() must not be boolean

2021-02-13 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION This error raise when I trying use the upload.py <https://www.mediawiki.org/wiki/Manual:Pywikibot/upload.py> script with the par

[Pywikipedia-bugs] [Maniphest] [Retitled] T248372: Critical exceptionl: local variable 'relative_filename' referenced before assignment

2020-03-24 Thread Vladis13
Vladis13 renamed this task from "Critica exceptionl: local variable 'relative_filename' referenced before assignment" to "Critical exceptionl: local variable 'relative_filename' referenced before assignment". TASK DETAIL https://phabricator.wikimedia.org/T248372 EMAIL

[Pywikipedia-bugs] [Maniphest] [Created] T248372: Critica exceptionl: local variable 'relative_filename' referenced before assignment

2020-03-24 Thread Vladis13
Vladis13 created this task. Vladis13 added a project: Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION A my bot on wmftools falls with follows exception. Since this commit <https://phabricator.wikimedia.

[Pywikipedia-bugs] [Maniphest] [Edited] T246298: Ability to change a label name for new Wikidata items in Pywikibot

2020-02-28 Thread Vladis13
Vladis13 updated the task description. TASK DETAIL https://phabricator.wikimedia.org/T246298 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Aklapper, pywikibot-bugs-list, Vladis13, Zkhalido, Viztor, Wenyi, Tbscho, MayS, Mdupont, JJMC89

[Pywikipedia-bugs] [Maniphest] [Created] T246298: Ability to change a label name for new Wikidata items in Pywikibot

2020-02-26 Thread Vladis13
Vladis13 created this task. Vladis13 added projects: Pywikibot-Wikidata, Pywikibot. Restricted Application added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION Pywikibot creates a page items with a label equivalent to the page name. See pywikibot.bot.create_item_for_page

[Pywikipedia-bugs] [Maniphest] [Commented On] T142155: Bot can't login. keyError in GetCookie

2016-11-08 Thread Vladis13
Vladis13 added a comment. @Tgr yes, on https://www.mediawiki.org/wiki/Manual:Pywikibot/Installation again was not updated version number 2.0rc4. So I thought that my version Pwb is actual. I make Oauth, but Pwb still ask password. I tried make Oauth from both accounts - user and bot, then write

[Pywikipedia-bugs] [Maniphest] [Commented On] T142155: Bot can't login. keyError in GetCookie

2016-11-01 Thread Vladis13
Vladis13 added a comment. Work nothing: login, Oauth, Botpassword. :( I don't understand, there the common login has broken at past week and it temporary bug? Or it forever, now only Oauth, which dont work?TASK DETAILhttps://phabricator.wikimedia.org/T142155EMAIL PREFERENCEShttps

[Pywikipedia-bugs] [Maniphest] [Commented On] T142021: Error mysqlquery

2016-08-07 Thread Vladis13
Vladis13 added a comment. In T142021#2528747, @Mpaa wrote: mpaa@tools-bastion-03:~/core$ cat file.txt Thanks. But I just wrote the little script on php: http://tools.wmflabs.org/ruwikisource/WDBquery_transcludes_templatesTASK DETAILhttps://phabricator.wikimedia.org/T142021EMAIL PREFERENCEShttps

[Pywikipedia-bugs] [Maniphest] [Commented On] T142021: Error mysqlquery

2016-08-07 Thread Vladis13
Vladis13 added a comment. In T142021#2528739, @Mpaa wrote: You got your query wrong. mpaa@tools-bastion-03:~/core$ python scripts/listpages.py -mysqlquery:"SELECT page_namespace, page_title FROM page WHERE page_namespace = 0 LIMIT 10" You run it from user-home directory, I install

[Pywikipedia-bugs] [Maniphest] [Commented On] T142021: Error mysqlquery

2016-08-04 Thread Vladis13
Vladis13 added a comment. I repoted to Qursql. But I doubt that there will be repaired and ever be answered. Problem of Pwb is that the error is now, and no way works with MySQL, and old info in documentation. Also, "python scripts\listpages.py" does not write a list of pag

[Pywikipedia-bugs] [Maniphest] [Commented On] T142021: Error mysqlquery

2016-08-03 Thread Vladis13
Vladis13 added a comment. I wanted list pages that transcludes a template, for use in an autonomous script. Now command "python scripts\listpages.py -transcludes" seems works. Perhaps something reinstalled at tries above. I will try get the list by call "import os ; os.system(comm

[Pywikipedia-bugs] [Maniphest] [Commented On] T142021: Error mysqlquery

2016-08-03 Thread Vladis13
Vladis13 added a comment. Turns out, oursql has a branch for Python 3. But pip install oursql3 give error too: "utf-8' codec can't decode byte 0xcd in position 20: invalid continuation byte".TASK DETAILhttps://phabricator.wikimedia.org/T142021EMAIL PREFERENCEShttps://phabricator.wik

[Pywikipedia-bugs] [Maniphest] [Commented On] T142021: Error mysqlquery

2016-08-03 Thread Vladis13
Vladis13 added a comment. "pip install oursql" occurs errors too. Oursql is critical outdated from 2012. On install it breaks on old format command "print " and something problem with Visual Studio. Also it require install "cython". "pip install python-my

[Pywikipedia-bugs] [Maniphest] [Edited] T142021: Error mysqlquery

2016-08-03 Thread Vladis13
Vladis13 edited the task description. (Show Details) EDIT DETAILS...E.g. //python scripts\listpages.py -mysqlquery:"py -mysqlquery:"SELECT * FROM page LIMIT 10"// or //list = pywikibot.pagegenerators.MySQLPageGenerator('SELECT * FROM page LIMIT 10"10')/

[Pywikipedia-bugs] [Maniphest] [Created] T142021: Error mysqlquery

2016-08-03 Thread Vladis13
Vladis13 created this task.Vladis13 added a project: Pywikibot-core.Herald added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTIONWhen run listpages.py -mysqlquery (or call function pagegenerators.py) occurs error that not found modules "oursql" and "MySQLdb". T

[Pywikipedia-bugs] [Maniphest] [Created] T132273: Error generate_user_files.py - version of Windows 10

2016-04-09 Thread Vladis13
Vladis13 created this task. Herald added subscribers: pywikibot-bugs-list, Aklapper. TASK DESCRIPTION Does not run generate_user_files.py on Windows 10 File "C:\pwb\pywikibot\config2.py", line 278, in get_base_dir % win_version) OSError: Windows version 1 not sup

[Pywikipedia-bugs] [Maniphest] [Commented On] T112130: Pywikibot crashes on items with quantities with units. Need to implement unit support in pywikibot WbQuanity

2016-04-07 Thread Vladis13
Vladis13 added a comment. i dont TASK DETAIL https://phabricator.wikimedia.org/T112130 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: Vladis13 Cc: Vladis13, ArthurPSmith, zhuyifei1999, jayvdb, Ladsgroup, gerritbot, Aklapper, pywikibot-bugs-list

[Pywikipedia-bugs] [Maniphest] [Commented On] T112130: Pywikibot crashes on items with quantities with units. Need to implement unit support in pywikibot WbQuanity

2016-04-06 Thread Vladis13
Vladis13 added a comment. In https://phabricator.wikimedia.org/T112130#2184242, @Vladis13 wrote: > This error was on old version <https://www.wikidata.org/w/index.php?title=Q4115189=319286502=319259767> item "Wikidata:Sandbox <https://www.wikidata.org/wiki/Q411

[Pywikipedia-bugs] [Maniphest] [Commented On] T112130: Pywikibot crashes on items with quantities with units. Need to implement unit support in pywikibot WbQuanity

2016-04-06 Thread Vladis13
Vladis13 added a comment. I get the error when try run "Example 9: Add a source <https://www.wikidata.org/wiki/Wikidata:Creating_a_bot#Example_9:_Add_a_source>" from manual "Wikidata:Creating a bot". import pywikibot repo = pywikibot.Site("wikidat