about summary refs log tree commit diff
path: root/pkgs/development/python-modules/oelint-parser/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/python-modules/oelint-parser/default.nix')
-rw-r--r--pkgs/development/python-modules/oelint-parser/default.nix47
1 files changed, 30 insertions, 17 deletions
diff --git a/pkgs/development/python-modules/oelint-parser/default.nix b/pkgs/development/python-modules/oelint-parser/default.nix
index be36594a57cfe..fbef31e9f50a0 100644
--- a/pkgs/development/python-modules/oelint-parser/default.nix
+++ b/pkgs/development/python-modules/oelint-parser/default.nix
@@ -1,41 +1,54 @@
 {
   lib,
   nix-update-script,
-  fetchPypi,
+  fetchFromGitHub,
   buildPythonPackage,
+  setuptools,
   deprecated,
   regex,
-  pip,
+  pytest-cov-stub,
+  pytest-forked,
+  pytest-random-order,
+  pytestCheckHook,
 }:
 
 buildPythonPackage rec {
   pname = "oelint-parser";
-  version = "3.5.3";
-  format = "setuptools";
+  version = "5.1.0";
+  pyproject = true;
 
-  src = fetchPypi {
-    inherit version;
-    pname = "oelint_parser";
-    hash = "sha256-ExW/wSuuLQH6MB9PIXjmHgdUxhqX6AXnKPDe9PJ2T/4=";
+  src = fetchFromGitHub {
+    owner = "priv-kweihmann";
+    repo = "oelint-parser";
+    rev = "refs/tags/${version}";
+    hash = "sha256-0cCcbnipijQgWH+08eZbE6Cqcx5cenrb+bQlf3h04tw=";
   };
 
-  buildInputs = [ pip ];
-  propagatedBuildInputs = [
-    deprecated
+  pythonRelaxDeps = [ "regex" ];
+
+  build-system = [ setuptools ];
+
+  dependencies = [
     regex
+    deprecated
+  ];
+
+  nativeCheckInputs = [
+    pytest-cov-stub
+    pytest-forked
+    pytest-random-order
+    pytestCheckHook
   ];
-  pythonImportsCheck = [ "oelint_parser" ];
 
-  # Fail to run inside the code the build.
-  doCheck = false;
+  pythonImportsCheck = [ "oelint_parser" ];
 
   passthru.updateScript = nix-update-script { };
 
-  meta = with lib; {
+  meta = {
     description = "Alternative parser for bitbake recipes";
     homepage = "https://github.com/priv-kweihmann/oelint-parser";
     changelog = "https://github.com/priv-kweihmann/oelint-parser/releases/tag/${version}";
-    license = licenses.bsd2;
-    maintainers = with maintainers; [ otavio ];
+    license = lib.licenses.bsd2;
+    maintainers = with lib.maintainers; [ otavio ];
   };
 }