python312Packages.textnets: fix build on darwin
This commit is contained in:
parent
0c87981c32
commit
c6afce43c2
@ -1,24 +1,30 @@
|
|||||||
{
|
{
|
||||||
lib,
|
lib,
|
||||||
|
stdenv,
|
||||||
buildPythonPackage,
|
buildPythonPackage,
|
||||||
cairocffi,
|
|
||||||
cython,
|
|
||||||
en_core_web_sm,
|
|
||||||
fetchFromGitHub,
|
fetchFromGitHub,
|
||||||
|
|
||||||
|
# build-system
|
||||||
|
cython,
|
||||||
|
poetry-core,
|
||||||
|
setuptools,
|
||||||
|
|
||||||
|
# dependencies
|
||||||
|
cairocffi,
|
||||||
igraph,
|
igraph,
|
||||||
leidenalg,
|
leidenalg,
|
||||||
pandas,
|
pandas,
|
||||||
poetry-core,
|
|
||||||
pyarrow,
|
pyarrow,
|
||||||
pytestCheckHook,
|
|
||||||
pythonOlder,
|
|
||||||
scipy,
|
scipy,
|
||||||
setuptools,
|
|
||||||
spacy-lookups-data,
|
|
||||||
spacy,
|
spacy,
|
||||||
|
spacy-lookups-data,
|
||||||
toolz,
|
toolz,
|
||||||
tqdm,
|
tqdm,
|
||||||
wasabi,
|
wasabi,
|
||||||
|
|
||||||
|
# tests
|
||||||
|
en_core_web_sm,
|
||||||
|
pytestCheckHook,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
@ -26,8 +32,6 @@ buildPythonPackage rec {
|
|||||||
version = "0.9.5";
|
version = "0.9.5";
|
||||||
pyproject = true;
|
pyproject = true;
|
||||||
|
|
||||||
disabled = pythonOlder "3.9";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "jboynyc";
|
owner = "jboynyc";
|
||||||
repo = "textnets";
|
repo = "textnets";
|
||||||
@ -63,8 +67,8 @@ buildPythonPackage rec {
|
|||||||
];
|
];
|
||||||
|
|
||||||
nativeCheckInputs = [
|
nativeCheckInputs = [
|
||||||
pytestCheckHook
|
|
||||||
en_core_web_sm
|
en_core_web_sm
|
||||||
|
pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
||||||
pythonImportsCheck = [ "textnets" ];
|
pythonImportsCheck = [ "textnets" ];
|
||||||
@ -74,16 +78,25 @@ buildPythonPackage rec {
|
|||||||
rm -r textnets
|
rm -r textnets
|
||||||
'';
|
'';
|
||||||
|
|
||||||
disabledTests = [
|
disabledTests =
|
||||||
|
[
|
||||||
# Test fails: Throws a UserWarning asking the user to install `textnets[fca]`.
|
# Test fails: Throws a UserWarning asking the user to install `textnets[fca]`.
|
||||||
"test_context"
|
"test_context"
|
||||||
|
]
|
||||||
|
++ lib.optionals stdenv.hostPlatform.isDarwin [
|
||||||
|
# MemoryError: ("cairo returned CAIRO_STATUS_NO_MEMORY: b'out of memory'", 1)
|
||||||
|
"test_plot_backbone"
|
||||||
|
"test_plot_filtered"
|
||||||
|
"test_plot_layout"
|
||||||
|
"test_plot_projected"
|
||||||
|
"test_plot_scaled"
|
||||||
];
|
];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = {
|
||||||
description = "Text analysis with networks";
|
description = "Text analysis with networks";
|
||||||
homepage = "https://textnets.readthedocs.io";
|
homepage = "https://textnets.readthedocs.io";
|
||||||
changelog = "https://github.com/jboynyc/textnets/blob/v${version}/HISTORY.rst";
|
changelog = "https://github.com/jboynyc/textnets/blob/v${version}/HISTORY.rst";
|
||||||
license = licenses.gpl3Only;
|
license = lib.licenses.gpl3Only;
|
||||||
maintainers = with maintainers; [ jboy ];
|
maintainers = with lib.maintainers; [ jboy ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user