tests(cross-runtime-serde): hide torch-trt DLLs on Windows too#4343
Merged
tp5uiuc merged 1 commit intoJun 22, 2026
Merged
Conversation
``_cross_runtime_load_helper.py:_hide_so_files()`` globbed only the Linux/macOS-style ``libtorchtrt*`` pattern. On Windows the runtime libraries are named ``torchtrt.dll`` / ``torchtrt_runtime.dll`` (no ``lib`` prefix; see ``py/torch_tensorrt/_features.py``), so the glob returned an empty list and the spawned subprocess kept ``torch_tensorrt_runtime`` True, tripping the ``C++ runtime should be disabled`` assertion in all three ``test_cross_runtime_serde.py`` tests on Windows L2 dynamo compile runners. Make the glob platform-aware: ``torchtrt*.dll`` + ``torchtrt*.lib`` on Windows, ``libtorchtrt*`` elsewhere.
Collaborator
Author
|
[by Claude Code] CI analysis: all red checks on the current run are pre-existing/infra failures, none caused by this 1-file test-helper change.
Counts where visible: 3/68 (python-only dynamo runtime), 5/1977 (dynamo converter), 10/19 (dynamo core). All builds pass (Linux x86_64, Windows, SBSA, Jetpack, RTX). Linters + CLA pass. Caveat: |
Collaborator
Author
|
Let me merge this one in, the $/! for rerunning L2 for a one-line change is questionable. We can confirm from post-merge runs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
tests/py/dynamo/models/_cross_runtime_load_helper.py:_hide_so_files()only globbed theLinux/macOS-style
libtorchtrt*pattern. On Windows the Torch-TensorRT runtime librariesare named
torchtrt.dll/torchtrt_runtime.dll(nolibprefix; seepy/torch_tensorrt/_features.py), so the glob returned an empty list and the spawnedPython-only subprocess kept
torch_tensorrt_runtime == True, tripping theC++ runtime should be disabledassertion.Make the glob platform-aware:
torchtrt*.dll,torchtrt*.liblibtorchtrt*(unchanged)Fixes the three
test_cross_runtime_serde.pyfailures on the Windows L2 dynamo compilerunners surfaced in #4330:
test_save_cpp_load_pythontest_save_python_load_pythontest_save_python_load_cppType of change
Checklist: