Page MenuHomePhabricator

replace.py: async output messages jumbled with user interaction on main thread
Open, LowPublic

Description

when running replace.py with manual confirming of each replace, bot have often some pages in save queue. In compat all messages about saving appeared after confirming some of next

>>>Page 1<<<
- FOO
+ BAR
Do you fant to accept... [y/n]y
Page [[Lorem]] saved
Page [[Ipsum]]saved

In core these messages sometimes appears before confirming 

No changes were necessary in [[Ivan Král vydá po dvanácti letech nové album]]
Page [[Izrael popřel, že by střílel na vozidlo OSN]] saved

>>> Je zvažováno obnovení meziměstské tramvaje mezi Bratislavou a Vídní <<<
-  | odkaz na periodikum = IDnes
+  | odkaz na periodikum = IDNES.cz

Do you want to accept these changes? ([y]es, [N]o, [e]dit, open in [b]rowser, [a
]ll, [q]uit) Page [[Italka odpojená po letech od vyživovacích přístrojů zemřela]
] saved
y

Version: core-(2.0)
Severity: normal

Details

Reference
bz71646
Related Gerrit Patches:

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:45 AM
bzimport set Reference to bz71646.
bzimport added a subscriber: Unknown Object (????).
JAnD created this task.Oct 4 2014, 8:36 PM
jayvdb changed the task status from Open to Stalled.Jun 9 2015, 5:57 AM
jayvdb triaged this task as Medium priority.
jayvdb updated the task description. (Show Details)
jayvdb edited projects, added Pywikibot-replace.py; removed Pywikibot-Scripts.
jayvdb set Security to None.
Mpaa added a subscriber: Mpaa.Oct 23 2015, 9:33 PM

Change 248680 had a related patch set uploaded (by Mpaa):
Control output message when saving in async mode

https://gerrit.wikimedia.org/r/248680

Mpaa changed the task status from Stalled to Open.Oct 25 2015, 10:14 AM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 25 2015, 10:14 AM

Change 248680 merged by jenkins-bot:
Control output message when saving.

https://gerrit.wikimedia.org/r/248680

jayvdb closed this task as Resolved.Nov 10 2015, 6:26 AM
jayvdb assigned this task to Mpaa.
Xqt reopened this task as Open.Apr 11 2016, 6:53 PM
Xqt added a subscriber: Xqt.

Reopened. I think the current implementation is not very usefull because that problem not only occurs on replace.py and subclasses of that bot but all scripts putting asynchroneous have this problem. This is core-specific and does not occur in compat because there is a cache_output implemented when any input aquires input_lock. Refer # User output/logging functions in wikipedia.py.

Change 282818 had a related patch set uploaded (by Xqt):
[bugfix] Port cache_output from compat

https://gerrit.wikimedia.org/r/282818

Xqt raised the priority of this task from Medium to High.May 28 2017, 11:55 AM
Dvorapa lowered the priority of this task from High to Low.May 31 2018, 7:19 PM
D3r1ck01 moved this task from Backlog to Needs Review on the Pywikibot board.Nov 5 2018, 11:38 AM