Skip to content

Commit 48f01db

Browse files
authored
Add 3.14 support (#830)
1 parent 38b5b5c commit 48f01db

File tree

4 files changed

+18
-0
lines changed

4 files changed

+18
-0
lines changed

.github/matrix.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,15 @@
99
"container-options": "--gpus all",
1010
"alias": "a10g"
1111
},
12+
{
13+
"runner": "linux.g5.4xlarge.nvidia.gpu",
14+
"python-version": "3.14",
15+
"ref-eager": false,
16+
"image": "nvidia/cuda:12.8.1-devel-ubuntu24.04",
17+
"runtime-version": "cu128",
18+
"container-options": "--gpus all",
19+
"alias": "a10g"
20+
},
1221
{
1322
"runner": "linux.g5.4xlarge.nvidia.gpu",
1423
"python-version": "3.12",

helion/_testing.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,11 @@ def skipIfLowVRAM(
8080
return unittest.skipIf(os.environ.get("HELION_DEV_LOW_VRAM", "0") == "1", reason)
8181

8282

83+
def skipIfPy314(reason: str) -> Callable[[Callable], Callable]:
84+
"""Skip test if running on Python 3.14"""
85+
return unittest.skipIf(sys.version_info >= (3, 14), reason)
86+
87+
8388
@contextlib.contextmanager
8489
def track_run_ref_calls() -> Generator[list[int], None, None]:
8590
"""Context manager that tracks BoundKernel.run_ref calls.

test/test_torch_compile.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,14 @@
88
from helion._testing import DEVICE
99
from helion._testing import RefEagerTestBase
1010
from helion._testing import TestCase
11+
from helion._testing import skipIfPy314
1112
from helion._testing import skipIfRefEager
1213
import helion.language as hl
1314

1415

1516
class TestTorchCompile(RefEagerTestBase, TestCase):
1617
@skipIfRefEager("does not work with ref eager")
18+
@skipIfPy314("torch.compile not yet supported on Python 3.14")
1719
def test_add_kernel(self):
1820
@helion.kernel(config=helion.Config(block_sizes=[1, 2]))
1921
def add(x: torch.Tensor, y: torch.Tensor) -> torch.Tensor:

test/test_views.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
from helion._testing import RefEagerTestBase
1010
from helion._testing import TestCase
1111
from helion._testing import code_and_output
12+
from helion._testing import skipIfPy314
1213
from helion._testing import skipIfRocm
1314
import helion.language as hl
1415

@@ -315,6 +316,7 @@ def test_stack_non_power_of_2_kernel(
315316
torch.testing.assert_close(result, expected, rtol=1e-5, atol=1e-5)
316317
self.assertExpectedJournal(code)
317318

319+
@skipIfPy314("torch.compile not yet supported on Python 3.14")
318320
def test_stack_dim0(self):
319321
@helion.kernel(use_default_config=True, static_shapes=True)
320322
def test_stack_dim0_kernel(

0 commit comments

Comments
 (0)