jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/346589 )
Change subject: Add _items for WbMonolingualText ......................................................................
Add _items for WbMonolingualText
This enables a __str__ and __repr__ for this class. Also fixes whitespace issue (E305) at end of the class.
Change-Id: Ibba69fb19aaaf799f658323e0b3012cc1be121c2 --- M pywikibot/__init__.py 1 file changed, 3 insertions(+), 0 deletions(-)
Approvals: jenkins-bot: Verified Xqt: Looks good to me, approved
diff --git a/pywikibot/__init__.py b/pywikibot/__init__.py index 273e538..eff852a 100644 --- a/pywikibot/__init__.py +++ b/pywikibot/__init__.py @@ -772,6 +772,8 @@ class WbMonolingualText(_WbRepresentation): """A Wikibase monolingual text representation."""
+ _items = ('text', 'language') + def __init__(self, text, language): """ Create a new WbMonolingualText object. @@ -809,6 +811,7 @@ """ return cls(wb['text'], wb['language'])
+ _sites = {} _url_cache = {} # The code/fam pair for each URL
pywikibot-commits@lists.wikimedia.org