jenkins-bot has submitted this change. ( https://gerrit.wikimedia.org/r/c/pywikibot/core/+/640929 )
Change subject: [bugfix] Do not strip all whitespaces from title ......................................................................
[bugfix] Do not strip all whitespaces from title
Bug: T197642 Change-Id: Ia482218cc569e566dbd8bfd0927a469667e0a26c --- M pywikibot/page/__init__.py 1 file changed, 3 insertions(+), 3 deletions(-)
Approvals: JJMC89: Looks good to me, approved jenkins-bot: Verified
diff --git a/pywikibot/page/__init__.py b/pywikibot/page/__init__.py index fdc1973..4142102 100644 --- a/pywikibot/page/__init__.py +++ b/pywikibot/page/__init__.py @@ -5988,9 +5988,9 @@
# "empty" local links can only be self-links # with a fragment identifier. - if not t.strip() and not self._is_interwiki: - raise pywikibot.InvalidTitle('The link does not contain a page ' - 'title') + if not t.strip(' ') and not self._is_interwiki: # T197642 + raise pywikibot.InvalidTitle( + 'The link does not contain a page title')
if self._site.namespaces[self._namespace].case == 'first-letter': t = first_upper(t)
pywikibot-commits@lists.wikimedia.org