Files
nixpkgs/pkgs/development/python-modules/django-weasyprint/default.nix
T
Hugo Herter bd17e4551c python3Packages.django-weasyprint: disable failing test with weasyprint 68
test_get_pdf_download_and_options tries to open /static/css/print.css
in the Nix test environment and fails with FileNotFoundError.

Disable this single upstream test so the package keeps building while
retaining the rest of the test suite.
2026-03-04 11:17:51 +01:00

51 lines
1.0 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
django,
weasyprint,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "django-weasyprint";
version = "2.4.0";
pyproject = true;
src = fetchFromGitHub {
owner = "fdemmer";
repo = "django-weasyprint";
tag = "v${version}";
hash = "sha256-eSh1p+5MyYb6GIEgSdlFxPzVCenlkwSCTkTzgKjezIg=";
};
build-system = [
setuptools
];
dependencies = [
django
weasyprint
];
nativeCheckInputs = [
pytestCheckHook
];
disabledTests = [
# Fails with weasyprint >= 68 (tries to open /static/css/print.css in test env)
"test_get_pdf_download_and_options"
];
pythonImportsCheck = [ "django_weasyprint" ];
meta = {
description = "Django class-based view generating PDF resposes using WeasyPrint";
homepage = "https://github.com/fdemmer/django-weasyprint";
changelog = "https://github.com/fdemmer/django-weasyprint/releases/tag/${src.tag}";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ hoh ];
};
}