Skip to content

Commit

Permalink
Merge pull request #72 from lucascolley/array_namespace-error
Browse files Browse the repository at this point in the history
MAINT: improve error message for `array_namespace`
  • Loading branch information
rgommers authored Jan 3, 2024
2 parents 9e53230 + 4c1d7b9 commit d235910
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion array_api_compat/common/_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def your_function(x, y):
namespaces.add(torch)
else:
# TODO: Support Python scalars?
raise TypeError("The input is not a supported array type")
raise TypeError(f"{type(x).__name__} is not a supported array type")

if not namespaces:
raise TypeError("Unrecognized array input")
Expand Down

0 comments on commit d235910

Please sign in to comment.