Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions tensorrt_llm/executor/proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -675,12 +675,11 @@ def _register_worker_processes(self, status: tuple) -> None:
"""Register identities returned by locally spawned MPI workers.

Test session reuse replaces this module's ``MpiPoolSession`` class
reference with a factory, so identify pool-backed sessions by excluding
the external communication session types.
reference with a factory, so use the polymorphic ``is_comm_session``
predicate rather than ``isinstance`` — the module-level symbol may be
rebound to a factory at runtime, breaking ``isinstance``.
"""
if not isinstance(
self.mpi_session,
(MpiCommSession, RemoteMpiCommSessionClient)) and len(status) == 3:
if not self.mpi_session.is_comm_session() and len(status) == 3:

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The stated root cause doesn't apply to the line being replaced: the old check tested isinstance(self.mpi_session, (MpiCommSession, RemoteMpiCommSessionClient)) — it never referenced the rebound MpiPoolSession, so it could not raise TypeError. On top of that, tests/test_common/_session_utils.py:44 (_isinstance_transparent_shim) now installs a real class with __instancecheck__ at the seam, so isinstance against the patched attribute works too.

So this is a readability refactor, not a fix — fine to keep, but the comment should say that rather than describe a failure mode this code can't hit. If the polymorphic predicate is the preferred form, apply it at proxy.py:143 as well, which still uses the isinstance version for the same distinction.

One behavior difference worth noting: is_comm_session() requires the session object to expose the method. _ReusableSession is not an MpiSession subclass but delegates via __getattr__, so it's fine; any future duck-typed session that isn't would now get an AttributeError where isinstance silently returned False.

worker_process_identities: List[WorkerProcessIdentity] = status[2]
self._worker_process_monitor.register(worker_process_identities)

Expand Down
2 changes: 0 additions & 2 deletions tests/integration/test_lists/waives.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ accuracy/test_disaggregated_serving.py::TestQwen3_30B_A3B::test_mixed_ctx_gen_mo
accuracy/test_llm_api_autodeploy.py::TestNemotronNanoV3::test_accuracy[nvfp4-4-attn_dp_off-trtllm] SKIP (https://nvbugs/6367792)
accuracy/test_llm_api_autodeploy.py::TestNemotronSuperV3::test_mtp[nvfp4_ws8_80gb-trtllm] SKIP (https://nvbugs/6450341)
accuracy/test_llm_api_autodeploy.py::TestQwen3_5_397B_MoE::test_bf16_small[4] SKIP (https://nvbugs/6507114)
accuracy/test_llm_api_pytorch.py::TestDeepSeekR1::test_fp8_blockscale[throughput] SKIP (https://nvbugs/6561775)
accuracy/test_llm_api_pytorch.py::TestDeepSeekR1::test_fp8_blockscale[throughput_mtp] SKIP (https://nvbugs/6428101)
accuracy/test_llm_api_pytorch.py::TestDeepSeekR1::test_fp8_blockscale[throughput_mtp_trtllm] SKIP (https://nvbugs/6426868)
accuracy/test_llm_api_pytorch.py::TestDeepSeekR1::test_nvfp4_multi_gpus[latency] SKIP (https://nvbugs/6561778)
Expand Down Expand Up @@ -232,7 +231,6 @@ full:H100/accuracy/test_disaggregated_serving.py::TestDeepSeekV3Lite::test_auto_
full:H100/accuracy/test_llm_api_pytorch.py::TestDeepSeekV3Lite::test_bfloat16[mtp_nextn=2-attention_dp=True-cuda_graph=True-overlap_scheduler=True-torch_compile=True-enable_chunked_prefill=True-v2_kv_cache=False] SKIP (https://nvbugs/6422343)
full:H100/accuracy/test_llm_api_pytorch.py::TestDeepSeekV3Lite::test_bfloat16[mtp_nextn=2-attention_dp=True-cuda_graph=True-overlap_scheduler=True-torch_compile=True-enable_chunked_prefill=True-v2_kv_cache=True] SKIP (https://nvbugs/6422343)
full:H100/accuracy/test_llm_api_pytorch.py::TestGPTOSS::test_w4_1gpu[v2_kv_cache-True-True-cutlass-auto] SKIP (https://nvbugs/6529792)
full:H100/accuracy/test_llm_api_pytorch.py::TestQwen3_30B_A3B_Instruct_2507::test_skip_softmax_attention_4gpus[target_sparsity_0.9-fp8kv=False] SKIP (https://nvbugs/6523809)
full:H100/accuracy/test_llm_api_pytorch.py::TestQwen3_5_35B_A3B::test_bf16[tp1-CUTLASS] SKIP (https://nvbugs/6273850)
full:H100/disaggregated/test_disaggregated.py::test_disaggregated_logprobs_serving[llama-3.1-8b-instruct] SKIP (https://nvbugs/6275959)
full:H100/disaggregated/test_disaggregated.py::test_disaggregated_stress_test[input8k-output1k-conc512-qwen3_32b_fp8_stress] SKIP (https://nvbugs/6312828)
Expand Down
Loading