jenkins-bot submitted this change.
[cleanup] Raise a TypeError if BaseBot.init_page return None
Change-Id: I467753707f36e7961c03ff01267f52982064b39f
---
M pywikibot/bot.py
1 file changed, 1 insertion(+), 9 deletions(-)
diff --git a/pywikibot/bot.py b/pywikibot/bot.py
index 2777fad6..b8df65d 100644
--- a/pywikibot/bot.py
+++ b/pywikibot/bot.py
@@ -1575,15 +1575,7 @@
try:
for item in self.generator:
# preprocessing of the page
- initialized_page = self.init_page(item)
- if initialized_page is None:
- issue_deprecation_warning(
- 'Returning None from init_page() method',
- 'return a pywikibot.page.BasePage object',
- since='20200406')
- page = item
- else:
- page = initialized_page
+ page = self.init_page(item)
# validate page type
if not isinstance(page, self.treat_page_type):
To view, visit change 737202. To unsubscribe, or for help writing mail filters, visit settings.