Files
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

80 lines
1.5 KiB
Nix

{
lib,
python3,
fetchFromGitHub,
wrapQtAppsHook,
}:
python3.pkgs.buildPythonApplication rec {
pname = "sasview";
version = "5.0.6";
pyproject = true;
src = fetchFromGitHub {
owner = "SasView";
repo = "sasview";
rev = "refs/tags/v${version}";
hash = "sha256-cwP9VuvO4GPlbAxCqw31xISTi9NoF5RoBQmjWusrnzc=";
};
# AttributeError: module 'numpy' has no attribute 'float'.
postPatch = ''
substituteInPlace src/sas/sascalc/pr/p_invertor.py \
--replace "dtype=np.float)" "dtype=float)"
'';
nativeBuildInputs = [
python3.pkgs.pyqt5
python3.pkgs.setuptools
wrapQtAppsHook
];
propagatedBuildInputs = with python3.pkgs; [
bumps
h5py
lxml
periodictable
pillow
pyparsing
pyqt5
qt5reactor
sasmodels
scipy
setuptools
xhtml2pdf
];
postBuild = ''
${python3.interpreter} src/sas/qtgui/convertUI.py
'';
dontWrapQtApps = true;
makeWrapperArgs = [
"\${qtWrapperArgs[@]}"
];
nativeCheckInputs = with python3.pkgs; [
pytestCheckHook
unittest-xml-reporting
];
enabledTestPaths = [
"test"
];
disabledTests = [
# NoKnownLoaderException
"test_invalid_cansas"
"test_data_reader_exception"
];
meta = {
description = "Fitting and data analysis for small angle scattering data";
homepage = "https://www.sasview.org";
changelog = "https://github.com/SasView/sasview/releases/tag/v${version}";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ rprospero ];
};
}