Closed cyyever closed 1 month ago
This seems to fix an xfail
in the WASM / Pyodide wheel
job:
____________________ test_cross_module_exception_translator ____________________
[XPASS(strict)] See Issue #2847, PR #2999, PR #4324
I'm too rushed to look carefully, but that looks good?
Did you mean to (also) remove or sys.platform.startswith('emscripten')
?
@rwgk I have no emscripten env, but I tested on Apple Silicon and it worked. Therefore I removed the MacOS+CPython case.
I have no emscripten env, but I tested on Apple Silicon and it worked. Therefore I removed the MacOS+CPython case.
We have the WASM / Pyodide wheel
job here in our GitHub Actions.
Could you please remove or sys.platform.startswith('emscripten')
? I believe that'll fix the test failures, which would be awesome.
@rwgk Removed
Description
Before this PR, exception translation was still failing on libc++. The failure reason is the visibility of exceptions, which was already discovered in #2999 and reverted by #4324. This PR fixes it by detecting libc++ using the _LIBCPP_EXCEPTION macro and setting PYBIND11_EXPORT_EXCEPTION accordingly. The macro definition is moved below other C++ header inclusion to make sure that _LIBCPP_EXCEPTION is defined.
Suggested changelog entry: