Skip to content

Commit 1c82878

Browse files
davidberard98pytorchmergebot
authored andcommitted
[test][dynamo] skip test_deopt_from_append_list on python>=3.13.3 (pytorch#155167)
Not sure why, apparently this test starts passing on python 3.13.3 (while it fails on python <=3.13.2) and it's causing unexpected passes on xfail-ed tests when newer versions of python are used, e.g. in pytorch#155056. Verified locally in a python 3.13.1 vs. python 3.13.3 conda env. Pull Request resolved: pytorch#155167 Approved by: https://github.com/williamwen42
1 parent 93012d2 commit 1c82878

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

test/dynamo/cpython/3_13/test_list.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@
2727
"test.typinganndata.ann_module",
2828
)
2929

30+
def xfailIfBelow3133(func):
31+
return unittest.expectedFailure(func) if sys.version_info < (3, 13, 3) else func
32+
3033
class RedirectImportFinder(importlib.abc.MetaPathFinder):
3134
def find_spec(self, fullname, path, target=None):
3235
# Check if the import is the problematic one
@@ -373,7 +376,7 @@ def test_tier2_invalidates_iterator(self):
373376
a.append(4)
374377
self.assertEqual(list(it), [])
375378

376-
@unittest.expectedFailure
379+
@xfailIfBelow3133
377380
def test_deopt_from_append_list(self):
378381
# gh-132011: it used to crash, because
379382
# of `CALL_LIST_APPEND` specialization failure.

0 commit comments

Comments
 (0)