diff --git a/pkgs/development/python-modules/setuptools-odoo/default.nix b/pkgs/development/python-modules/setuptools-odoo/default.nix index a9129334208f..5e262daa580e 100644 --- a/pkgs/development/python-modules/setuptools-odoo/default.nix +++ b/pkgs/development/python-modules/setuptools-odoo/default.nix @@ -1,20 +1,25 @@ -{ buildPythonPackage +{ lib +, buildPythonPackage , fetchFromGitHub -, lib -, nix-update-script -, pytestCheckHook , git +, pytestCheckHook +, pythonOlder , setuptools-scm , writeScript }: + buildPythonPackage rec { pname = "setuptools-odoo"; - version = "3.1.12"; + version = "3.2.1"; + format = "setuptools"; + + disabled = pythonOlder "3.7"; + src = fetchFromGitHub { owner = "acsone"; repo = pname; - rev = version; - hash = "sha256-GIX21gOENE0r3yFIyzwjaoEcb0XvuCqiPU8F3GLxNt4="; + rev = "refs/tags/${version}"; + hash = "sha256-aS2a1G9lssgGk3uqWgPPWpOpEnqUkCUzWsqPLQfU55k="; }; propagatedBuildInputs = [ @@ -23,6 +28,7 @@ buildPythonPackage rec { # HACK https://github.com/NixOS/nixpkgs/pull/229460 SETUPTOOLS_SCM_PRETEND_VERSION = version; + patchPhase = '' runHook prePatch @@ -55,7 +61,11 @@ buildPythonPackage rec { preBuildHooks+=(setuptoolsOdooHook) ''; - nativeCheckInputs = [ pytestCheckHook git ]; + nativeCheckInputs = [ + pytestCheckHook + git + ]; + disabledTests = [ "test_addon1_uncommitted_change" "test_addon1" @@ -65,12 +75,11 @@ buildPythonPackage rec { "test_odoo_addon5_wheel" ]; - passthru.updateScript = nix-update-script { }; - - meta = { + meta = with lib; { description = "Setuptools plugin for Odoo addons"; homepage = "https://github.com/acsone/setuptools-odoo"; - license = lib.licenses.lgpl3Only; - maintainers = with lib.maintainers; [ yajo ]; + changelog = "https://github.com/acsone/setuptools-odoo/blob/${version}/CHANGES.rst"; + license = licenses.lgpl3Only; + maintainers = with maintainers; [ yajo ]; }; }