From 68626acba30ab59fa1ef27c25eb7ed93f227396e Mon Sep 17 00:00:00 2001 From: Guilherme Leobas Date: Thu, 8 Aug 2019 08:31:42 -0300 Subject: DEP: Deprecate np.alen (#14181) * Deprecate and fix tests for alen --- numpy/core/fromnumeric.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'numpy/core/fromnumeric.py') diff --git a/numpy/core/fromnumeric.py b/numpy/core/fromnumeric.py index 75a6bae7f..c9ea44425 100644 --- a/numpy/core/fromnumeric.py +++ b/numpy/core/fromnumeric.py @@ -2782,6 +2782,10 @@ def alen(a): 7 """ + # NumPy 1.18.0, 2019-08-02 + warnings.warn( + "`np.alen` is deprecated, use `len` instead", + DeprecationWarning, stacklevel=2) try: return len(a) except TypeError: -- cgit v1.2.1