1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4, pytest-asyncio
5, pytestCheckHook
6, pythonOlder
7}:
8
9buildPythonPackage rec {
10 pname = "dynalite-devices";
11 version = "0.47";
12 format = "setuptools";
13
14 disabled = pythonOlder "3.7";
15
16 src = fetchFromGitHub {
17 owner = "ziv1234";
18 repo = "python-dynalite-devices";
19 rev = "refs/tags/v${version}";
20 hash = "sha256-kJo4e5vhgWzijLUhQd9VBVk1URpg9SXhOA60dJYashM=";
21 };
22
23 postPatch = ''
24 sed -i '/^addopts/d' setup.cfg
25 '';
26
27 nativeCheckInputs = [
28 pytest-asyncio
29 pytestCheckHook
30 ];
31
32 pytestFlagsArray = [
33 "--asyncio-mode=auto"
34 ];
35
36 pythonImportsCheck = [
37 "dynalite_devices_lib"
38 ];
39
40 meta = with lib; {
41 description = "An unofficial Dynalite DyNET interface creating devices";
42 homepage = "https://github.com/ziv1234/python-dynalite-devices";
43 changelog = "https://github.com/ziv1234/python-dynalite-devices/releases/tag/v${version}";
44 license = licenses.mit;
45 maintainers = with maintainers; [ dotlambda ];
46 };
47}