jenkins-bot has submitted this change and it was merged. ( https://gerrit.wikimedia.org/r/564433 )
Change subject: [cleanup] Announce Site.has_api method to be removed ......................................................................
[cleanup] Announce Site.has_api method to be removed
Pywikibot core only supports MediaWiki which has API. Therefore the compat method has_api can be removed after 5 years.
Change-Id: I847894bda56536b70b8609b8d487aee2f4c55b55 --- M pywikibot/site.py 1 file changed, 2 insertions(+), 2 deletions(-)
Approvals: Mpaa: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/site.py b/pywikibot/site.py index a3e72bb..a2bde12 100644 --- a/pywikibot/site.py +++ b/pywikibot/site.py @@ -783,7 +783,7 @@ self._pagemutex = threading.Condition() self._locked_pages = set()
- @deprecated(since='20141225') + @deprecated(since='20141225', future_warning=True) def has_api(self): """Return whether this site has an API.""" return False @@ -1883,7 +1883,7 @@ return pywikibot.Site(url=site['url'] + '/w/index.php') raise ValueError('Cannot parse a site out of %s.' % dbname)
- @deprecated(since='20141225') + @deprecated(since='20141225', future_warning=True) def has_api(self): """Return whether this site has an API.""" return True
pywikibot-commits@lists.wikimedia.org