37 buildPythonPackage rec {
42 disabled = pythonOlder "3.7";
45 inherit pname version;
46 hash = "sha256-Szfr0lraQFmw3J4Ik+cN3l34NIUymgaO8EWA5wiSpl0=";
50 # spaCy is compatible with NumPy v1 and v2
51 substituteInPlace pyproject.toml setup.cfg \
52 --replace-fail "numpy>=2.0.0,<2.1.0" numpy
95 # Fixes ModuleNotFoundError when running tests on Cythonized code. See #255262
100 pytestFlagsArray = [ "-m 'slow'" ];
104 "test_download_compatibility"
105 "test_validate_compatibility_table"
106 "test_project_assets"
109 pythonImportsCheck = [ "spacy" ];
112 updateScript = writeScript "update-spacy" ''
123 nix-update python3Packages.spacy
125 # update spacy models as well
126 echo | nix-shell maintainers/scripts/update.nix --argstr package python3Packages.spacy-models.en_core_web_sm
128 tests.annotation = callPackage ./annotation-test { };
132 description = "Industrial-strength Natural Language Processing (NLP)";
133 mainProgram = "spacy";
134 homepage = "https://github.com/explosion/spaCy";
135 changelog = "https://github.com/explosion/spaCy/releases/tag/release-v${version}";
136 license = licenses.mit;