diff --git a/pkgs/development/python-modules/ngxparse/default.nix b/pkgs/development/python-modules/ngxparse/default.nix new file mode 100644 index 000000000000..3e919eb6063b --- /dev/null +++ b/pkgs/development/python-modules/ngxparse/default.nix @@ -0,0 +1,36 @@ +{ + lib, + buildPythonPackage, + fetchFromGitHub, + setuptools, + pytestCheckHook, +}: + +buildPythonPackage rec { + pname = "ngxparse"; + version = "0.5.16"; + pyproject = true; + + # Fetching from GitHub because the PyPI sdist is missing the test fixtures + src = fetchFromGitHub { + owner = "dvershinin"; + repo = "crossplane"; + tag = "v${version}"; + hash = "sha256-gXzVjY89YjppneR9Vuce+V+RKIcbIBEvLeAoI54ZegM="; + }; + + build-system = [ setuptools ]; + + nativeCheckInputs = [ pytestCheckHook ]; + + # The ngxparse distribution ships its importable module as `crossplane` + # (it's a drop-in replacement for the upstream nginxinc/crossplane). + pythonImportsCheck = [ "crossplane" ]; + + meta = { + description = "Reliable and fast NGINX configuration file parser (maintained fork of crossplane)"; + homepage = "https://github.com/dvershinin/crossplane"; + license = lib.licenses.asl20; + maintainers = with lib.maintainers; [ dvershinin ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index f4ff36be4137..2c6a1611631c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -11214,6 +11214,8 @@ self: super: with self; { nglview = callPackage ../development/python-modules/nglview { }; + ngxparse = callPackage ../development/python-modules/ngxparse { }; + nh3 = callPackage ../development/python-modules/nh3 { }; nhc = callPackage ../development/python-modules/nhc { };