Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / pysigma-backend-elasticsearch / default.nix
blob2a9ae5011d892cbde010fab5c855c452bae9a29c
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , poetry-core
5 , pysigma
6 , pytestCheckHook
7 , pythonOlder
8 , requests
9 }:
11 buildPythonPackage rec {
12   pname = "pysigma-backend-elasticsearch";
13   version = "1.0.12";
14   pyproject = true;
16   disabled = pythonOlder "3.8";
18   src = fetchFromGitHub {
19     owner = "SigmaHQ";
20     repo = "pySigma-backend-elasticsearch";
21     rev = "refs/tags/v${version}";
22     hash = "sha256-ibCwTZymgd+VuE4UXbYxUyIbzlpfIdc2zE8Nz/vhBGQ=";
23   };
25   postPatch = ''
26     substituteInPlace pyproject.toml \
27       --replace-fail " --cov=sigma --cov-report term --cov-report xml:cov.xml" ""
28   '';
30   nativeBuildInputs = [
31     poetry-core
32   ];
34   propagatedBuildInputs = [
35     pysigma
36   ];
38   nativeCheckInputs = [
39     pytestCheckHook
40     requests
41   ];
43   pythonImportsCheck = [
44     "sigma.backends.elasticsearch"
45   ];
47   disabledTests = [
48     # Tests requires network access
49     "test_connect_lucene"
50   ];
52   meta = with lib; {
53     description = "Library to support Elasticsearch for pySigma";
54     homepage = "https://github.com/SigmaHQ/pySigma-backend-elasticsearch";
55     changelog = "https://github.com/SigmaHQ/pySigma-backend-elasticsearch/releases/tag/v${version}";
56     license = with licenses; [ lgpl21Only ];
57     maintainers = with maintainers; [ fab ];
58   };