jenkins-bot submitted this change.

View Change

Approvals: Xqt: Looks good to me, approved jenkins-bot: Verified
cleanup: Remove Family.linktrail()

Bug: T378898
Change-Id: I50b3473d740be80f3f731899ca83cadc60f12997
---
M ROADMAP.rst
M pywikibot/family.py
2 files changed, 3 insertions(+), 16 deletions(-)

diff --git a/ROADMAP.rst b/ROADMAP.rst
index b5b5478..7a65372 100644
--- a/ROADMAP.rst
+++ b/ROADMAP.rst
@@ -14,6 +14,8 @@

**Code cleanups**

+* ``linktrail`` method of :class:`family.Family` was removed;
+ use :meth:`APISite.linktrail()<pywikibot.site._apisite.APISite.linktrail>` instead
* Positional arguments *decoder*, *layer* and *newline* for :mod:`logging` functions are invalid;
keyword arguments must be used instead.
* The positional arguments of :meth:`page.BasePage.linkedPages` were removed.
@@ -117,8 +119,6 @@
-------------------------------

* 9.4.0: :mod:`flow` support is deprecated and will be removed (:phab:`T371180`)
-* 7.3.0: ``linktrail`` method of :class:`family.Family` is deprecated; use :meth:`APISite.linktrail()
- <pywikibot.site._apisite.APISite.linktrail>` instead
* 7.2.0: ``tb`` parameter of :func:`exception()<pywikibot.logging.exception>` function was renamed to ``exc_info``
* 7.1.0: Unused ``get_redirect`` parameter of :meth:`Page.getOldVersion()<page.BasePage.getOldVersion>` will be removed
* 7.0.0: baserevid parameter of editSource(), editQualifier(), removeClaims(), removeSources(), remove_qualifiers()
diff --git a/pywikibot/family.py b/pywikibot/family.py
index 094a4ea..f72b4db 100644
--- a/pywikibot/family.py
+++ b/pywikibot/family.py
@@ -25,7 +25,7 @@
from pywikibot.backports import DefaultDict, Mapping, Sequence, removesuffix
from pywikibot.data import wikistats
from pywikibot.exceptions import FamilyMaintenanceWarning, UnknownFamilyError
-from pywikibot.tools import classproperty, deprecated, remove_last_args
+from pywikibot.tools import classproperty, deprecated


logger = logging.getLogger('pywiki.wiki.family')
@@ -393,19 +393,6 @@
Family._families[fam] = cls
return cls

- @deprecated('APISite.linktrail()', since='7.3.0')
- @remove_last_args(['fallback'])
- def linktrail(self, code: str) -> str:
- """Return regex for trailing chars displayed as part of a link.
-
- .. note:: Returns a string, not a compiled regular expression
- object.
-
- .. deprecated:: 7.3
- """
- site = pywikibot.Site(code, 'wikipedia')
- return site.linktrail()
-
def category_redirects(self, code, fallback: str = '_default'):
"""Return list of category redirect templates."""
if not hasattr(self, '_catredirtemplates') \

To view, visit change 1101203. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: merged
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I50b3473d740be80f3f731899ca83cadc60f12997
Gerrit-Change-Number: 1101203
Gerrit-PatchSet: 3
Gerrit-Owner: Xqt <info@gno.de>
Gerrit-Reviewer: Xqt <info@gno.de>
Gerrit-Reviewer: jenkins-bot