BUG: Fix gh-15888 for HiGHs OOM crashes #18990
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
More of a dodge than a fix, but will essentially work with exceptions now.
Reference issue
Closes #15888.
What does this implement/fix?
This is an extension to the bindings for the exception handling introduced in
highs
here: scipy/HiGHS#61The
pybind11
bindings ofhighspy
also support handling C++ exceptions so even after integrating directly withhighspy
this should not be an issue.Additional information
N/A. I intend to also have an upstream PR on exceptions so the fork changes are minimized.
To test this locally one has to update the submodule to point to scipy/HiGHS#61.
Draft until scipy/HiGHS#61 is completed and until a custom exception is raised and caught (instead of catching
Exception
in thecython
binding).Note: The build will be broken until the HiGHS PR is merged :)