Skip to content

Commit 4f7c569

Browse files
committed
Remove domdf_python_tools.utils.deprecated
1 parent c3e3355 commit 4f7c569

File tree

2 files changed

+6
-18
lines changed

2 files changed

+6
-18
lines changed

domdf_python_tools/utils.py

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@
2222
:func:`~domdf_python_tools.iterative.Len`, and
2323
:func:`~domdf_python_tools.iterative.double_chain`
2424
moved to :func:`domdf_python_tools.iterative`.
25+
26+
.. versionchanged:: 2.3.0
27+
28+
Removed :func:`domdf_python_tools.utils.deprecated`.
29+
Use the new `deprecation-alias <https://pypi.org/project/deprecation-alias/>`_ package instead.
30+
2531
"""
2632
#
2733
# Copyright © 2018-2020 Dominic Davis-Foster <[email protected]>
@@ -41,10 +47,6 @@
4147
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
4248
# MA 02110-1301, USA.
4349
#
44-
# check_dependencies based on https://stackoverflow.com/a/29044693/3092681
45-
# Copyright © 2015 TehTechGuy
46-
# Licensed under CC-BY-SA
47-
#
4850
# as_text from https://stackoverflow.com/a/40935194
4951
# Copyright © 2016 User3759685
5052
# Available under the MIT License
@@ -65,12 +67,8 @@
6567
from pprint import pformat
6668
from typing import TYPE_CHECKING, Any, Callable, Dict, Iterable, List, Optional, Tuple, Union
6769

68-
# 3rd party
69-
from deprecation_alias import deprecated
70-
7170
# this package
7271
import domdf_python_tools.words
73-
from domdf_python_tools import __version__
7472
from domdf_python_tools.typing import HasHead, String
7573

7674
if TYPE_CHECKING or domdf_python_tools.__docs: # pragma: no cover
@@ -96,7 +94,6 @@
9694
"convert_indents",
9795
"etc",
9896
"head",
99-
"deprecated",
10097
"magnitude",
10198
"trim_precision",
10299
]
@@ -339,14 +336,6 @@ def head(obj: Union[Tuple, List, "DataFrame", "Series", String, HasHead], n: int
339336
return str(obj[:n]) + etc # type: ignore
340337

341338

342-
deprecated = deprecated(
343-
deprecated_in="2.0.0",
344-
removed_in="2.3.0",
345-
current_version=__version__,
346-
details="Use the new 'deprecation-alias' package instead."
347-
)(deprecated) # yapf: disable
348-
349-
350339
def magnitude(x: float) -> int:
351340
"""
352341
Returns the magnitude of the given value.

requirements.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
deprecation-alias>=0.1.1
21
importlib-metadata>=1.5.0; python_version < "3.8"
32
importlib-resources>=3.0.0; python_version < "3.7"
43
natsort>=7.1.0

0 commit comments

Comments
 (0)