From 68dd877e3d3f28ab211d1d10beec3df5a813e386 Mon Sep 17 00:00:00 2001 From: Lein Matsumaru Date: Tue, 14 Jul 2026 15:14:17 +0000 Subject: [PATCH] python3Packages.textacy: fix build --- .../python-modules/textacy/default.nix | 28 +++++++++++++------ 1 file changed, 19 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/textacy/default.nix b/pkgs/development/python-modules/textacy/default.nix index 4fbaf9486083..651bee904baa 100644 --- a/pkgs/development/python-modules/textacy/default.nix +++ b/pkgs/development/python-modules/textacy/default.nix @@ -1,6 +1,8 @@ { lib, buildPythonPackage, + fetchFromGitHub, + setuptools, cachetools, cytoolz, fetchPypi, @@ -10,7 +12,6 @@ matplotlib, networkx, numpy, - pyemd, pyphen, pytestCheckHook, requests, @@ -20,26 +21,29 @@ tqdm, }: -buildPythonPackage rec { +buildPythonPackage (finalAttrs: { pname = "textacy"; version = "0.13.0"; pyproject = true; + __structuredAttrs = true; - src = fetchPypi { - inherit pname version; - hash = "sha256-a+AkSMCPx9fE7fhSiQBuOaSlPvdHIB/yS2dcZS9AxoY="; + src = fetchFromGitHub { + owner = "chartbeat-labs"; + repo = "textacy"; + tag = finalAttrs.version; + hash = "sha256-QVxC9oV1X5ifQ9VVYissppni1A8LACz/FVgaoG5/GFU="; }; - propagatedBuildInputs = [ + build-system = [ setuptools ]; + + dependencies = [ cachetools cytoolz floret jellyfish joblib - matplotlib networkx numpy - pyemd pyphen requests scikit-learn @@ -48,6 +52,10 @@ buildPythonPackage rec { tqdm ]; + optional-dependencies = { + vis = [ matplotlib ]; + }; + nativeCheckInputs = [ pytestCheckHook ]; enabledTestPaths = [ @@ -64,6 +72,8 @@ buildPythonPackage rec { meta = { description = "Higher-level text processing, built on spaCy"; homepage = "https://textacy.readthedocs.io/"; + changelog = "https://github.com/chartbeat-labs/textacy/releases/tag/${finalAttrs.src.tag}"; license = lib.licenses.asl20; + maintainers = [ ]; }; -} +})