Skip to content

Commit 994e941

Browse files
committed
Import onnxruntime before loading the TensorRT provider in its test
<details><summary>Claude's draft</summary> The previous commit moved libonnxruntime_providers_tensorrt.so to $PREFIX/lib and, along the way, dropped `import onnxruntime` from the test. Without that import, dlopen of the TensorRT provider segfaults (status 139 on linux-64 and linux-aarch64 CUDA 13.4). The published 1.31.0 _202 build from main crashes the same way when run without the import, so the split is not the cause. Importing onnxruntime first loads the CUDA/cuDNN/TensorRT dependencies the provider expects, as happens in real use. Resume this Claude session: ``` cd /home/mark/git/feedstock claude --resume fdaba65c-5a43-4f26-a32f-d49b747fdbd7 ``` </details> Claude-Session: https://claude.ai/code/session_01R9WZp6UVaiXYyC2hWTNWZY
1 parent da13619 commit 994e941

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎recipe/recipe.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -391,7 +391,7 @@ outputs:
391391
tests:
392392
- script:
393393
# onnxruntime loads libonnxruntime_providers_shared globally before any provider.
394-
- python -c "import ctypes, os, sys; [ctypes.CDLL(os.path.join(sys.prefix, 'lib', f'libonnxruntime_providers_{p}.so'), os.RTLD_GLOBAL) for p in ('shared', 'tensorrt')]"
394+
- python -c "import ctypes, os, sys, onnxruntime; [ctypes.CDLL(os.path.join(sys.prefix, 'lib', f'libonnxruntime_providers_{p}.so'), os.RTLD_GLOBAL) for p in ('shared', 'tensorrt')]"
395395

396396
about:
397397
homepage: https://github.com/microsoft/onnxruntime/

0 commit comments

Comments
 (0)