Skip to content

Commit d235910

Browse files
authored
Merge pull request #72 from lucascolley/array_namespace-error
MAINT: improve error message for `array_namespace`
2 parents 9e53230 + 4c1d7b9 commit d235910

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: array_api_compat/common/_helpers.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def your_function(x, y):
9999
namespaces.add(torch)
100100
else:
101101
# TODO: Support Python scalars?
102-
raise TypeError("The input is not a supported array type")
102+
raise TypeError(f"{type(x).__name__} is not a supported array type")
103103

104104
if not namespaces:
105105
raise TypeError("Unrecognized array input")

0 commit comments

Comments
 (0)