jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/337059 )
Change subject: Update internals after removing claims ......................................................................
Update internals after removing claims
Change-Id: I819493b11fffb235a396005a747124aaad23b97f --- M pywikibot/page.py 1 file changed, 5 insertions(+), 1 deletion(-)
Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/page.py b/pywikibot/page.py index e44f393..a628efa 100644 --- a/pywikibot/page.py +++ b/pywikibot/page.py @@ -4450,7 +4450,11 @@ # list of length one. if isinstance(claims, pywikibot.Claim): claims = [claims] - self.repo.removeClaims(claims, **kwargs) + data = self.repo.removeClaims(claims, **kwargs) + for claim in claims: + claim.on_item.latest_revision_id = data['pageinfo']['lastrevid'] + claim.on_item = None + claim.snak = None
def mergeInto(self, item, **kwargs): """
pywikibot-commits@lists.wikimedia.org