Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
API: Always use BufferError when dlpack export fails
See also data-apis/array-api#498. I think we should just change this. It is a niche feature and just an error type change. Closes gh-20742
- Loading branch information
Showing
3 changed files
with
29 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
DLPack export raises ``BufferError`` | ||
------------------------------------ | ||
When an array buffer cannot be exported via DLPack a | ||
``BufferError`` is now always raised where previously | ||
``TypeError`` or ``RuntimeError`` was raised. | ||
This allows falling back to the buffer protocol or | ||
``__array_interface__`` when DLPack was tried first. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters