python314Packages.{sentence-transformers, llm, accelerate, llm-ollama, pydevd}: Python 3.14 fixes (#477241)

This commit is contained in:
Philip Taron
2026-01-06 00:53:23 +00:00
committed by GitHub
5 changed files with 41 additions and 9 deletions
@@ -162,7 +162,15 @@ buildPythonPackage rec {
++ lib.optionals (stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64) [
# RuntimeError: torch_shm_manager: execl failed: Permission denied
"CheckpointTest"
];
]
++
lib.optionals
(stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isx86_64 && (pythonAtLeast "3.14"))
[
# https://github.com/huggingface/accelerate/issues/3899
"test_accelerate_test"
"test_cpu"
];
disabledTestPaths = lib.optionals (!(stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isx86_64)) [
# numerous instances of torch.multiprocessing.spawn.ProcessRaisedException:
@@ -22,14 +22,14 @@
buildPythonPackage rec {
pname = "llm-ollama";
version = "0.14.0";
version = "0.15.1";
pyproject = true;
src = fetchFromGitHub {
owner = "taketwo";
repo = "llm-ollama";
tag = version;
hash = "sha256-8ELjUpHaIC8BOcmyQNeyQDPxQ5vO4Pj6FFnHFhvP+r0=";
hash = "sha256-iSLLFC+kYcKq6VOYspkgUyTobU6qUs7FxoAXBmm8H44=";
};
build-system = [ setuptools ];
@@ -6,6 +6,7 @@
fetchFromGitHub,
fetchpatch,
pytestCheckHook,
pythonAtLeast,
pythonOlder,
replaceVars,
setuptools,
@@ -249,6 +250,13 @@ let
# TypeError: CliRunner.__init__() got an unexpected keyword argument 'mix_stderr
# https://github.com/simonw/llm/issues/1293
"test_embed_multi_files_encoding"
]
++ lib.optionals (pythonAtLeast "3.14") [
# Index out of range
# https://github.com/simonw/llm/issues/1335
"test_logs_fragments"
"test_expand_fragment_json"
"test_expand_fragment_markdown"
];
pythonImportsCheck = [ "llm" ];
@@ -10,25 +10,25 @@
pytest-xdist,
pytestCheckHook,
pythonAtLeast,
pythonOlder,
trio,
untangle,
}:
buildPythonPackage rec {
pname = "pydevd";
version = "3.3.0";
version = "3.4.1";
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "fabioz";
repo = "PyDev.Debugger";
rev = "pydev_debugger_${lib.replaceStrings [ "." ] [ "_" ] version}";
hash = "sha256-V5pM0xnMFnpR1oK0purHFCV3wu+4fOmd72kmy7pVeyk=";
tag = "pydev_debugger_${lib.replaceStrings [ "." ] [ "_" ] version}";
hash = "sha256-srcYeN4IsnX/B0AWLynr62UC5o+DcjnUrGjcTpvHTCM=";
};
# https://github.com/fabioz/PyDev.Debugger/issues/316
disabled = pythonAtLeast "3.14";
postPatch = ''
sed -i '/addopts/d' pytest.ini
'';
@@ -49,6 +49,10 @@ buildPythonPackage rec {
untangle
];
enabledTestPaths = [
"tests/"
];
disabledTests = [
# Require network connection
"test_completion_sockets_and_messages"
@@ -3,6 +3,7 @@
stdenv,
buildPythonPackage,
fetchFromGitHub,
pythonAtLeast,
# build-system
setuptools,
@@ -128,6 +129,17 @@ buildPythonPackage rec {
# NameError: name 'ParallelismConfig' is not defined
"test_hf_argument_parser"
"test_hf_argument_parser_incorrect_string_arguments"
]
++ lib.optionals (pythonAtLeast "3.14") [
# TypeError: Pickler._batch_setitems() takes 2 positional arguments but 3 were given
# https://github.com/huggingface/sentence-transformers/issues/3606
"test_group_by_label_batch_sampler_label_a"
"test_group_by_label_batch_sampler_label_b"
"test_group_by_label_batch_sampler_uneven_dataset"
"test_proportional_no_duplicates"
"test_round_robin_batch_sampler"
"test_round_robin_batch_sampler_vallue_error"
]
++ lib.optionals (!stdenv.hostPlatform.isAarch64 && stdenv.hostPlatform.isDarwin) [
# These sparse tests also time out, on x86_64-darwin.