Skip to content

[Bug Skip]: [Failed to collect] [Regression] dynamo/test_misc_xpu.py fails to import: cannot import name 'TestTracer' from dynamo.test_misc #6142

Description

@torchxpubot

🐛 Describe the bug with skip template

Cases:
op_ut,,third_party.torch-xpu-ops.test.xpu.dynamo.test_misc_xpu

Summary

test/xpu/dynamo/test_misc_xpu.py imports TestTracer from the upstream test/dynamo/test_misc.py, which no longer defines that class, so the wrapper raises ImportError during collection and the entire module is lost - the baseline passed 1021 cases in it. The fix is in the XPU wrapper's import list, which has to drop or replace TestTracer. Upstream also removed the other jit-tracing dynamo cases in this same run (test_jit_trace_errors, test_script_function_graph_break and test_tracing_flags_scriptable_dynamic_shapes all appear as vanished), so this is most likely part of the same TorchScript removal as g1 and g2.

ErrorLog

ImportError: cannot import name 'TestTracer' from 'dynamo.test_misc' (/__w/torch-xpu-ops/torch-xpu-ops/pytorch/third_party/torch-xpu-ops/test/xpu/../../../../test/dynamo/test_misc.py)

ImportError while importing test module '/__w/torch-xpu-ops/torch-xpu-ops/pytorch/third_party/torch-xpu-ops/test/xpu/dynamo/test_misc_xpu.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/github/home/.local/share/uv/python/cpython-3.12.15-linux-x86_64-gnu/lib/python3.12/importlib/__init__.py:90: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
dynamo/test_misc_xpu.py:29: in <module>
    from dynamo.test_misc import (
E   ImportError: cannot import name 'TestTracer' from 'dynamo.test_misc' (/__w/torch-xpu-ops/torch-xpu-ops/pytorch/third_party/torch-xpu-ops/test/xpu/../../../../test/dynamo/test_misc.py)

Reproduce

cd pytorch/third_party/torch-xpu-ops/test/xpu
pytest -sv test_misc_xpu.py

Pytorch Version

Category Run Date torch torch-xpu-ops
op_ut Last good #42624021705 (op_ut) 2026-11-09 unknown unknown
op_ut First seen bad #42822758512 (op_ut) 2026-11-10 unknown unknown

These test files did not fail their cases - they erased them. A module that will not import reports one row and its cases never run at all.

Module Category In the baseline Cases it used to pass
third_party.torch-xpu-ops.test.xpu.dynamo.test_misc_xpu op_ut was passing 1021

Versions

Detail
collect_env output was not captured in this run's artifact.

Activity

  1. added
    regressionRegression with before/after version or commit signal
    skippedUsed for temp UT failure to parallel fix
    skipped_bmgTemporarily skipped on BMG
    on Nov 10, 2026
  2. torchxpubot commented on Nov 10, 2026

    @torchxpubot
    ContributorAuthor

    Same root cause as #6140, #6141, split because the cases do not share a classification or a row shape.

  3. added
    module: infraOnly for CICD infra used, no action need
    functionalityFunctional defect: error/assert/hang/timeout (non-numeric)
    test: utUnit-test failure surface
    on Nov 11, 2026
  4. added theissue type on Nov 11, 2026
  5. daisyden commented on Nov 11, 2026

    @daisyden
    Contributor
    label-issue: #6142

    Root cause: wrapper imports TestTracer from dynamo.test_misc (test/xpu/dynamo/test_misc_xpu.py:35); the 2026-11-10 nightly dropped it. Current viable/strict still defines it (test/dynamo/test_misc.py:20944) -> transient nightly regression; module collection erased (1021 baseline cases lost).

    axis value reason
    type Bug issue_type empty; collection ImportError erasing a whole passing module is a reported defect.
    test test: ut op_ut module-level import failure in test/xpu/dynamo/test_misc_xpu.py; no e2e/oob signal.
    module module: infra Defect is a stale test-wrapper import of a removed upstream class, not XPU dynamo code.
    priority High Regression (2026-11-09 good -> 2026-11-10 bad) erasing a module that passed 1021 baseline cases.
    symptom functionality ImportError at collection; the whole module fails to import.
    symptom regression Paired baselines: last good run 42624021705 (2026-11-09) vs first bad 42822758512 (2026-11-10).

    Applied to this issue. Generated by a local label-issue run.

  6. self-assigned this
    on Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

functionalityFunctional defect: error/assert/hang/timeout (non-numeric)module: infraOnly for CICD infra used, no action needregressionRegression with before/after version or commit signalskippedUsed for temp UT failure to parallel fixskipped_bmgTemporarily skipped on BMGtest: utUnit-test failure surface

Type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions