From 9e6090f955eb5944e62310f93bf3b4fe5e16a47f Mon Sep 17 00:00:00 2001 From: Florian Brandes Date: Tue, 14 May 2024 13:45:50 +0200 Subject: [PATCH 1/2] python311Packages.libgravatar: fix call to package Signed-off-by: Florian Brandes --- .../development/python-modules/libgravatar/default.nix | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/libgravatar/default.nix b/pkgs/development/python-modules/libgravatar/default.nix index f246f61a75a0..0168704c30b4 100644 --- a/pkgs/development/python-modules/libgravatar/default.nix +++ b/pkgs/development/python-modules/libgravatar/default.nix @@ -1,10 +1,12 @@ { lib, - python3Packages, + buildPythonPackage, fetchFromGitHub, + setuptools, + pytestCheckHook, }: -python3Packages.buildPythonApplication rec { +buildPythonPackage rec { pname = "libgravatar"; version = "1.0.4"; @@ -15,9 +17,9 @@ python3Packages.buildPythonApplication rec { hash = "sha256-rJv/jfdT+JldxR0kKtXQLOI5wXQYSQRWJnqwExwWjTA="; }; - nativeBuildInputs = with python3Packages; [ setuptools ]; + nativeBuildInputs = [ setuptools ]; - nativeCheckInputs = with python3Packages; [ pytestCheckHook ]; + nativeCheckInputs = [ pytestCheckHook ]; pythonImportsCheck = [ "libgravatar" ]; From d1800d1437537de7da1303aa2c10f907a2c607b6 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Wed, 15 May 2024 14:19:58 +0200 Subject: [PATCH 2/2] python312Packages.libgravatar: refactor --- pkgs/development/python-modules/libgravatar/default.nix | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/pkgs/development/python-modules/libgravatar/default.nix b/pkgs/development/python-modules/libgravatar/default.nix index 0168704c30b4..37d3373c7aa2 100644 --- a/pkgs/development/python-modules/libgravatar/default.nix +++ b/pkgs/development/python-modules/libgravatar/default.nix @@ -4,11 +4,15 @@ fetchFromGitHub, setuptools, pytestCheckHook, + pythonOlder, }: buildPythonPackage rec { pname = "libgravatar"; version = "1.0.4"; + pyproject = true; + + disabled = pythonOlder "3.8"; src = fetchFromGitHub { owner = "pabluk"; @@ -17,15 +21,16 @@ buildPythonPackage rec { hash = "sha256-rJv/jfdT+JldxR0kKtXQLOI5wXQYSQRWJnqwExwWjTA="; }; - nativeBuildInputs = [ setuptools ]; + build-system = [ setuptools ]; nativeCheckInputs = [ pytestCheckHook ]; pythonImportsCheck = [ "libgravatar" ]; meta = with lib; { - homepage = "https://github.com/pabluk/libgravatar"; description = "A library that provides a Python 3 interface for the Gravatar API"; + homepage = "https://github.com/pabluk/libgravatar"; + changelog = "https://github.com/pabluk/libgravatar/releases/tag/${version}"; license = licenses.gpl3Plus; maintainers = with maintainers; [ gador ]; };