Skip to content

Commit

Permalink
Prepare for NumPy 2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
nsoranzo committed Jun 19, 2024
1 parent 205f58a commit d8e8895
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/galaxy/model/custom_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class SafeJsonEncoder(json.JSONEncoder):
def default(self, obj):
if isinstance(obj, numpy.int_):
return int(obj)
elif isinstance(obj, numpy.float_):
elif isinstance(obj, numpy.float64):
return float(obj)
elif isinstance(obj, bytes):
return unicodify(obj)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ exclude = [
# Enable: pycodestyle errors (E), Pyflakes (F), flake8-bugbear (B),
# flake8-comprehensions (C4), flake8-logging-format (G),
# flake8-implicit-str-concat (ISC) and pyupgrade (UP)
select = ["E", "F", "B", "C4", "G", "ISC", "UP"]
select = ["E", "F", "B", "C4", "G", "ISC", "NPY", "UP"]
# Exceptions:
# B008 Do not perform function calls in argument defaults (for FastAPI Depends and Body)
# B9 flake8-bugbear opinionated warnings
Expand Down

0 comments on commit d8e8895

Please sign in to comment.