jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/559532 )
Change subject: Better error message handling, the error is not removed but kept ......................................................................
Better error message handling, the error is not removed but kept
In the old implementation the error object is modified, and so the error message is lost afterwords.
In the new implementation the message is just read and the error object is left unchanged.
Bug: T235500 Change-Id: I6aba2fc74894b170ca5375910c208b09c03087ba --- M pywikibot/data/api.py 1 file changed, 1 insertion(+), 1 deletion(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/data/api.py b/pywikibot/data/api.py index 4ae1892..5b0bb63 100644 --- a/pywikibot/data/api.py +++ b/pywikibot/data/api.py @@ -1612,7 +1612,7 @@ 'edit-already-exists', 'actionthrottledtext', # T192912 ) - messages = error.pop('messages', None) + messages = error.get('messages') message = None # bug T68619; after Wikibase breaking change 1ca9cee change we have a # list of messages
pywikibot-commits@lists.wikimedia.org