Skip to content

Expose exception text to C, Python and Rust API's#39

Merged
rapids-bot[bot] merged 2 commits into
NVIDIA:branch-24.04from
benfred:error_text
Mar 5, 2024
Merged

Expose exception text to C, Python and Rust API's#39
rapids-bot[bot] merged 2 commits into
NVIDIA:branch-24.04from
benfred:error_text

Conversation

@benfred

@benfred benfred commented Mar 4, 2024

Copy link
Copy Markdown
Contributor

Previously when something went wrong in the Rust or C API - all the end user would see is a CUVS_ERROR return code with no extra indication of what went wrong.

This change exposes the exception text to both the C and Rust api's, and provides a convenience method to automatically catch c++ exceptions, and convert the exception into an error code with the text set appropiately.

Previously when something went wrong in the Rust or C API - all the
end user would see is a `CUVS_ERROR` return code with no extra
indication of what went wrong.

This change exposes the exception text to both the C and Rust api's,
and provides a convenience method to automatically catch c++ exceptions,
and convert the exception into an error code with the text set appropiately.
@benfred benfred requested review from a team as code owners March 4, 2024 22:15
@github-actions github-actions Bot added the cpp label Mar 4, 2024
@benfred benfred added improvement Improves an existing functionality non-breaking Introduces a non-breaking change labels Mar 4, 2024
@dantegd

dantegd commented Mar 5, 2024

Copy link
Copy Markdown
Contributor

@benfred this is fantastic, @divyegala and me were discussing this since it also affects the Python API, this solution is quite nice!

@benfred benfred requested review from a team as code owners March 5, 2024 17:37
@benfred

benfred commented Mar 5, 2024

Copy link
Copy Markdown
Contributor Author

Thanks @dantegd ! I've updated the python side to also have the error text - let me know what you think,

@benfred benfred changed the title Expose exception text to C and Rust API's Expose exception text to C, Python and Rust API's Mar 5, 2024
@cjnolet

cjnolet commented Mar 5, 2024

Copy link
Copy Markdown
Contributor

/merge

@rapids-bot rapids-bot Bot merged commit b94c1b5 into NVIDIA:branch-24.04 Mar 5, 2024
@benfred benfred deleted the error_text branch March 5, 2024 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CMake cpp improvement Improves an existing functionality non-breaking Introduces a non-breaking change Python

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants