summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/portend/default.nix
blob: 737ac7ff866e8b6f12912603cc228c2223c6b270 (plain)
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
39
40
{
  lib,
  buildPythonPackage,
  fetchPypi,
  pytestCheckHook,
  setuptools-scm,
  tempora,
}:

buildPythonPackage rec {
  pname = "portend";
  version = "3.2.1";
  pyproject = true;

  src = fetchPypi {
    inherit pname version;
    hash = "sha256-qp1Aqx+eFL231AH0IhDfNdAXybl5kbrrGFaM7fuMZIk=";
  };

  postPatch = ''
    sed -i "/coherent\.licensed/d" pyproject.toml;
  '';

  build-system = [ setuptools-scm ];

  dependencies = [ tempora ];

  nativeCheckInputs = [ pytestCheckHook ];

  pythonImportsCheck = [ "portend" ];

  # Some of the tests use localhost networking.
  __darwinAllowLocalNetworking = true;

  meta = {
    description = "Monitor TCP ports for bound or unbound states";
    homepage = "https://github.com/jaraco/portend";
    license = lib.licenses.bsd3;
  };
}