diff options
Diffstat (limited to 'pkgs/development/python-modules/spacy/default.nix')
-rw-r--r-- | pkgs/development/python-modules/spacy/default.nix | 43 |
1 files changed, 20 insertions, 23 deletions
diff --git a/pkgs/development/python-modules/spacy/default.nix b/pkgs/development/python-modules/spacy/default.nix index d84599ffc8126..df9004d483ff6 100644 --- a/pkgs/development/python-modules/spacy/default.nix +++ b/pkgs/development/python-modules/spacy/default.nix @@ -1,7 +1,6 @@ { lib, stdenv, - blis, buildPythonPackage, callPackage, catalogue, @@ -10,19 +9,15 @@ fetchPypi, hypothesis, jinja2, - jsonschema, langcodes, mock, murmurhash, numpy, packaging, - pathy, preshed, pydantic, pytestCheckHook, - python, pythonOlder, - pythonRelaxDepsHook, requests, setuptools, spacy-legacy, @@ -31,7 +26,6 @@ thinc, tqdm, typer, - typing-extensions, wasabi, weasel, writeScript, @@ -42,37 +36,42 @@ buildPythonPackage rec { pname = "spacy"; - version = "3.7.4"; + version = "3.8.2"; pyproject = true; disabled = pythonOlder "3.7"; src = fetchPypi { inherit pname version; - hash = "sha256-Ul8s7S5AdhViyMrOk+9qHm6MSD8nvVZLwbFfYI776Fs="; + hash = "sha256-Szfr0lraQFmw3J4Ik+cN3l34NIUymgaO8EWA5wiSpl0="; }; - pythonRelaxDeps = [ - "smart-open" - "typer" - ]; + postPatch = '' + # spaCy is compatible with NumPy v1 and v2 + substituteInPlace pyproject.toml setup.cfg \ + --replace-fail "numpy>=2.0.0,<2.1.0" numpy + ''; - nativeBuildInputs = [ - pythonRelaxDepsHook + build-system = [ + cymem cython_0 + murmurhash + numpy + thinc + ]; + + pythonRelaxDeps = [ + "thinc" ]; - propagatedBuildInputs = [ - blis + dependencies = [ catalogue cymem jinja2 - jsonschema langcodes murmurhash numpy packaging - pathy preshed pydantic requests @@ -85,7 +84,7 @@ buildPythonPackage rec { typer wasabi weasel - ] ++ lib.optionals (pythonOlder "3.8") [ typing-extensions ]; + ]; nativeCheckInputs = [ pytestCheckHook @@ -93,8 +92,6 @@ buildPythonPackage rec { mock ]; - doCheck = true; - # Fixes ModuleNotFoundError when running tests on Cythonized code. See #255262 preCheck = '' cd $out @@ -135,8 +132,8 @@ buildPythonPackage rec { description = "Industrial-strength Natural Language Processing (NLP)"; mainProgram = "spacy"; homepage = "https://github.com/explosion/spaCy"; - changelog = "https://github.com/explosion/spaCy/releases/tag/v${version}"; + changelog = "https://github.com/explosion/spaCy/releases/tag/release-v${version}"; license = licenses.mit; - maintainers = with maintainers; [ ]; + maintainers = [ ]; }; } |