jenkins-bot has submitted this change. (
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1361154?usp=email )
Change subject: Remove deprecated date.dh and OptionSet parameter aliases
......................................................................
Remove deprecated date.dh and OptionSet parameter aliases
The filter parameter of date.dh and the dict parameter of OptionSet
were deprecated in Pywikibot 9 and are scheduled for removal in
Pywikibot 12. Remove their argument adapters, unused imports, and
pending-removal entries from ROADMAP.rst.
Callers must use filter_func and data respectively.
Change-Id: Iee3e1a65d3e33bd06355b936ab37fc9231102348
---
M ROADMAP.rst
M pywikibot/data/api/_optionset.py
M pywikibot/date.py
3 files changed, 1 insertion(+), 6 deletions(-)
Approvals:
Xqt: Looks good to me, approved
jenkins-bot: Verified
diff --git a/ROADMAP.rst b/ROADMAP.rst
index eda9d22..9ce6dda 100644
--- a/ROADMAP.rst
+++ b/ROADMAP.rst
@@ -49,8 +49,6 @@
<pywikibot.site._generators.GeneratorsMixin.protectedpages>` was renamed to
``protect_type``
* 9.0.0: The ``all`` parameter of :meth:`site.APISite.namespace()
<pywikibot.site._apisite.APISite.namespace>` was renamed to ``all_ns``
-* 9.0.0: ``filter`` parameter of :func:`date.dh` was renamed to ``filter_func``
-* 9.0.0: ``dict`` parameter of :class:`data.api.OptionSet` was renamed to
``data``
* 9.0.0: ``allrevisions`` parameter of :class:`xmlreader.XmlDump` is
deprecated, use ``revisions`` instead
(:phab:`T340804`)
diff --git a/pywikibot/data/api/_optionset.py b/pywikibot/data/api/_optionset.py
index e1f7f2c..600638a 100644
--- a/pywikibot/data/api/_optionset.py
+++ b/pywikibot/data/api/_optionset.py
@@ -9,7 +9,6 @@
from collections.abc import MutableMapping
import pywikibot
-from pywikibot.tools import deprecate_arg
__all__ = ['OptionSet']
@@ -27,7 +26,6 @@
None) will fail.
"""
- @deprecate_arg('dict', 'data') # since 9.0
def __init__(self,
site: pywikibot.site.APISite | None = None,
module: str | None = None,
diff --git a/pywikibot/date.py b/pywikibot/date.py
index b9f0ecb..b974576 100644
--- a/pywikibot/date.py
+++ b/pywikibot/date.py
@@ -18,7 +18,7 @@
from pywikibot import Site
from pywikibot.site import BaseSite
-from pywikibot.tools import deprecate_arg, first_lower, first_upper
+from pywikibot.tools import first_lower, first_upper
from pywikibot.userinterfaces.transliteration import NON_ASCII_DIGITS
@@ -454,7 +454,6 @@
@singledispatch
-@deprecate_arg('filter', 'filter_func') # since 9.0
def dh(value: int, pattern: str, encf: encf_type, decf: decf_type,
filter_func: Callable[[int], bool] | None = None) -> str:
"""Function to help with year parsing.
--
To view, visit
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/1361154?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.wikimedia.org/r/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: Iee3e1a65d3e33bd06355b936ab37fc9231102348
Gerrit-Change-Number: 1361154
Gerrit-PatchSet: 2
Gerrit-Owner: Mahveotm <[email protected]>
Gerrit-Reviewer: Xqt <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]