You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Self-contained NpyString declarations in utf8_ext.pyx for older numpy pxds
The NpyString C API has been in the NumPy headers since 2.0, but its
Cython declarations only appear in the numpy/__init__.pxd of newer NumPy
versions. The Pyodide cross-build pins an older NumPy (2.1's pxd has none
of them), so cythonizing utf8_ext.pyx failed on wasm32 with
"'npy_string_allocator' is not a type identifier". Declare the four
symbols locally instead of via `cimport numpy`; they resolve through the
API table populated by cnp.import_array(), so no behavior changes.
Verified by reproducing the failure with numpy 2.1.3 + Cython 3.2.8,
then cythonizing, compiling, and running the kernel in that same env.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
0 commit comments