Skip to content

Commit cd84c7c

Browse files
committed
bug: remove deprecated np.complex_ bump version
1 parent 664daf7 commit cd84c7c

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

numpyencoder/numpyencoder.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,12 @@ def default(self, obj):
2222
np.uint64,
2323
),
2424
):
25-
2625
return int(obj)
2726

2827
elif isinstance(obj, (np.float16, np.float32, np.float64)):
2928
return float(obj)
3029

31-
elif isinstance(obj, (np.complex_, np.complex64, np.complex128)):
30+
elif isinstance(obj, (np.complex64, np.complex128)):
3231
return {"real": obj.real, "imag": obj.imag}
3332

3433
elif isinstance(obj, (np.ndarray,)):

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
setup(
77
name="numpyencoder",
8-
version="0.3.1",
8+
version="0.3.2",
99
author="Hunter M. Allen",
1010
author_email="allenhm@gmail.com",
1111
license="MIT",

0 commit comments

Comments
 (0)