Skip to content

Commit 123dba4

Browse files
committed
fixup! REF: Created pandas.core.arrays
1 parent 6e084ad commit 123dba4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/core/arrays/categorical.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -557,7 +557,7 @@ def from_codes(cls, codes, categories, ordered=False):
557557
"""
558558
try:
559559
codes = np.asarray(codes, np.int64)
560-
except:
560+
except (ValueError, TypeError):
561561
raise ValueError(
562562
"codes need to be convertible to an arrays of integers")
563563

0 commit comments

Comments
 (0)