Skip to content

Commit eb815ae

Browse files
authored
Add 3.12 to unittest CI jobs (#8299)
1 parent 8afd547 commit eb815ae

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

.github/workflows/prototype-tests-linux-gpu.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ jobs:
1212
- "3.9"
1313
- "3.10"
1414
- "3.11"
15+
- "3.12"
1516
runner: ["linux.12xlarge"]
1617
gpu-arch-type: ["cpu"]
1718
include:

.github/workflows/tests.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ jobs:
1818
- "3.9"
1919
- "3.10"
2020
- "3.11"
21+
- "3.12"
2122
runner: ["linux.12xlarge"]
2223
gpu-arch-type: ["cpu"]
2324
include:
@@ -51,6 +52,7 @@ jobs:
5152
- "3.9"
5253
- "3.10"
5354
- "3.11"
55+
- "3.12"
5456
runner: ["macos-12"]
5557
include:
5658
- python-version: "3.8"
@@ -81,6 +83,7 @@ jobs:
8183
- "3.9"
8284
- "3.10"
8385
- "3.11"
86+
- "3.12"
8487
runner: ["windows.4xlarge"]
8588
gpu-arch-type: ["cpu"]
8689
include:

test/test_transforms_v2.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,12 @@
5454

5555

5656
# turns all warnings into errors for this module
57-
pytestmark = pytest.mark.filterwarnings("error")
57+
pytestmark = [pytest.mark.filterwarnings("error")]
58+
59+
if sys.version_info[:2] >= (3, 12):
60+
# torchscript relies on some AST stuff that got deprecated in 3.12,
61+
# so we have to explicitly ignore those otherwise we'd error on warnings due to the pytestmark filter above.
62+
pytestmark.append(pytest.mark.filterwarnings("ignore::DeprecationWarning"))
5863

5964

6065
@pytest.fixture(autouse=True)

0 commit comments

Comments
 (0)