Skip to content

Commit 9cc0703

Browse files
authored
Stabilize Windows 3.14 notebook tests by avoiding loky backend (#138)
* Avoid loky backend in notebook tests on Windows 3.14 * Skip loky deadlock-prone tests on Windows Python 3.14
1 parent ad193e2 commit 9cc0703

3 files changed

Lines changed: 7 additions & 3 deletions

File tree

tests/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ def pytest_collection_modifyitems(session, config, items) -> None: # noqa: ARG0
8585

8686

8787
skip_if_deadlock = pytest.mark.skipif(
88-
(sys.version_info[:2] in [(3, 12), (3, 13)] and sys.platform == "win32")
88+
(sys.version_info[:2] in [(3, 12), (3, 13), (3, 14)] and sys.platform == "win32")
8989
or (sys.version_info[:2] == (3, 13) and sys.platform == "linux"),
9090
reason="Deadlock in loky/backend/resource_tracker.py, line 181, maybe related to https://github.com/joblib/loky/pull/450",
9191
)

tests/test_jupyter/test_functional_interface.ipynb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@
4444
"metadata": {},
4545
"outputs": [],
4646
"source": [
47-
"session = pytask.build(tasks=[create_file, create_text], n_workers=2)\n",
47+
"session = pytask.build(\n",
48+
" tasks=[create_file, create_text], n_workers=2, parallel_backend=\"processes\"\n",
49+
")\n",
4850
"assert session.exit_code == ExitCode.OK"
4951
]
5052
}

tests/test_jupyter/test_functional_interface_w_relative_path.ipynb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@
4444
"metadata": {},
4545
"outputs": [],
4646
"source": [
47-
"session = pytask.build(tasks=[create_file, create_text], n_workers=2)\n",
47+
"session = pytask.build(\n",
48+
" tasks=[create_file, create_text], n_workers=2, parallel_backend=\"processes\"\n",
49+
")\n",
4850
"assert session.exit_code == ExitCode.OK"
4951
]
5052
}

0 commit comments

Comments
 (0)