about summary refs log tree commit diff
path: root/pkgs/development/python-modules/construct-classes/default.nix
blob: e9daba610be8bdec8a6f3653f365b34fb38a8a58 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
{
  lib,
  stdenv,
  buildPythonPackage,
  fetchFromGitHub,
  poetry-core,
  construct,
  pytestCheckHook,
}:

buildPythonPackage rec {
  pname = "construct-classes";
  version = "0.1.2";
  format = "pyproject";

  # no tests in PyPI tarball
  src = fetchFromGitHub {
    owner = "matejcik";
    repo = "construct-classes";
    rev = "v${version}";
    hash = "sha256-l4sVacKTuQbhXCw2lVHCl1OzpCiKmEAm9nSQ8pxFuTo=";
  };

  nativeBuildInputs = [ poetry-core ];

  propagatedBuildInputs = [ construct ];

  nativeCheckInputs = [ pytestCheckHook ];

  pythonImportsCheck = [ "construct_classes" ];

  meta = with lib; {
    description = "Parse your binary data into dataclasses.";
    homepage = "https://github.com/matejcik/construct-classes";
    license = licenses.mit;
    maintainers = with maintainers; [ prusnak ];
  };
}