1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 substituteAll,
6 supervise,
7 setuptools,
8 pytestCheckHook,
9}:
10
11buildPythonPackage rec {
12 pname = "supervise-api";
13 version = "0.6.0";
14 pyproject = true;
15
16 src = fetchPypi {
17 pname = "supervise_api";
18 inherit version;
19 hash = "sha256-EjD0IpSRDoNCG307CKlo0n1RCkpwnpZlB+1w212hud4=";
20 };
21
22 postPatch = ''
23 substituteInPlace supervise_api/supervise.py \
24 --replace 'which("supervise")' '"${supervise}/bin/supervise"'
25 '';
26
27 nativeBuildInputs = [ setuptools ];
28
29 nativeCheckInputs = [ pytestCheckHook ];
30
31 pythonImportsCheck = [ "supervise_api" ];
32
33 meta = {
34 description = "API for running processes safely and securely";
35 homepage = "https://github.com/catern/supervise";
36 license = lib.licenses.mit;
37 platforms = lib.platforms.linux;
38 maintainers = with lib.maintainers; [ catern ];
39 };
40}