From 7c03fd0458a13b7499a12b244e2e218f3fc80576 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 9 Apr 2023 09:38:35 +0200 Subject: [PATCH 1/6] python310Packages.et_xmlfile: normalize pname --- .../python-modules/et_xmlfile/default.nix | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix index 538ed10cde36..9e3416540f75 100644 --- a/pkgs/development/python-modules/et_xmlfile/default.nix +++ b/pkgs/development/python-modules/et_xmlfile/default.nix @@ -6,15 +6,20 @@ }: buildPythonPackage rec { + pname = "et-xmlfile"; version = "1.0.1"; - pname = "et_xmlfile"; src = fetchPypi { - inherit pname version; + pname = "et_xmlfile"; + inherit version; sha256="0nrkhcb6jdrlb6pwkvd4rycw34y3s931hjf409ij9xkjsli9fkb1"; }; - nativeCheckInputs = [ lxml pytest ]; + nativeCheckInputs = [ + lxml + pytest + ]; + checkPhase = '' py.test $out ''; @@ -36,5 +41,4 @@ buildPythonPackage rec { license = licenses.mit; maintainers = with maintainers; [ ]; }; - } From 99a7b13af8e2585a441316ac746824087a2a0a02 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 9 Apr 2023 09:40:04 +0200 Subject: [PATCH 2/6] python310Packages.et_xmlfile: add pythonImportsCheck --- pkgs/development/python-modules/et_xmlfile/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix index 9e3416540f75..5d4b5e2ec61d 100644 --- a/pkgs/development/python-modules/et_xmlfile/default.nix +++ b/pkgs/development/python-modules/et_xmlfile/default.nix @@ -24,6 +24,10 @@ buildPythonPackage rec { py.test $out ''; + pythonImportsCheck = [ + "et_xmlfile" + ]; + meta = with lib; { description = "An implementation of lxml.xmlfile for the standard library"; longDescription = '' From 59a173d1c27dd4c777d7a26446459336e9bf9df5 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 9 Apr 2023 09:43:19 +0200 Subject: [PATCH 3/6] python310Packages.et_xmlfile: update homepage --- pkgs/development/python-modules/et_xmlfile/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix index 5d4b5e2ec61d..0d04e264c389 100644 --- a/pkgs/development/python-modules/et_xmlfile/default.nix +++ b/pkgs/development/python-modules/et_xmlfile/default.nix @@ -41,7 +41,7 @@ buildPythonPackage rec { The code was written by Elias Rabel as part of the Python Düsseldorf openpyxl sprint in September 2014. ''; - homepage = "https://pypi.python.org/pypi/et_xmlfile"; + homepage = "https://foss.heptapod.net/openpyxl/et_xmlfile"; license = licenses.mit; maintainers = with maintainers; [ ]; }; From b5f5ba93d6b299114d6a55a045737aaeb7e2c89f Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 9 Apr 2023 09:45:24 +0200 Subject: [PATCH 4/6] python310Packages.et_xmlfile: disable on unsupported releases - add format --- pkgs/development/python-modules/et_xmlfile/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix index 0d04e264c389..88028bae07e3 100644 --- a/pkgs/development/python-modules/et_xmlfile/default.nix +++ b/pkgs/development/python-modules/et_xmlfile/default.nix @@ -3,11 +3,15 @@ , fetchPypi , lxml , pytest +, pythonOlder }: buildPythonPackage rec { pname = "et-xmlfile"; version = "1.0.1"; + format = "setuptools"; + + disabled = pythonOlder "3.7"; src = fetchPypi { pname = "et_xmlfile"; From 429aff605527ad9a78140f97ee11e9cd306d6bb4 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 9 Apr 2023 09:47:31 +0200 Subject: [PATCH 5/6] python310Packages.et_xmlfile: move to pytestCheckHook --- pkgs/development/python-modules/et_xmlfile/default.nix | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix index 88028bae07e3..f09d0042003a 100644 --- a/pkgs/development/python-modules/et_xmlfile/default.nix +++ b/pkgs/development/python-modules/et_xmlfile/default.nix @@ -2,7 +2,7 @@ , buildPythonPackage , fetchPypi , lxml -, pytest +, pytestCheckHook , pythonOlder }: @@ -21,13 +21,9 @@ buildPythonPackage rec { nativeCheckInputs = [ lxml - pytest + pytestCheckHook ]; - checkPhase = '' - py.test $out - ''; - pythonImportsCheck = [ "et_xmlfile" ]; From f6ad3df1ecfc972c5a9b13e20369e6d66cd08fd3 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sun, 9 Apr 2023 10:00:56 +0200 Subject: [PATCH 6/6] python310Packages.et_xmlfile: 1.0.1 -> 1.1 Diff: https://foss.heptapod.net/openpyxl/et_xmlfile/-/compare/1.0.1...1.1 --- .../python-modules/et_xmlfile/default.nix | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/pkgs/development/python-modules/et_xmlfile/default.nix b/pkgs/development/python-modules/et_xmlfile/default.nix index f09d0042003a..b744d2a693dd 100644 --- a/pkgs/development/python-modules/et_xmlfile/default.nix +++ b/pkgs/development/python-modules/et_xmlfile/default.nix @@ -1,6 +1,6 @@ { lib , buildPythonPackage -, fetchPypi +, fetchFromGitLab , lxml , pytestCheckHook , pythonOlder @@ -8,15 +8,17 @@ buildPythonPackage rec { pname = "et-xmlfile"; - version = "1.0.1"; + version = "1.1"; format = "setuptools"; disabled = pythonOlder "3.7"; - src = fetchPypi { - pname = "et_xmlfile"; - inherit version; - sha256="0nrkhcb6jdrlb6pwkvd4rycw34y3s931hjf409ij9xkjsli9fkb1"; + src = fetchFromGitLab { + domain = "foss.heptapod.net"; + owner = "openpyxl"; + repo = "et_xmlfile"; + rev = version; + hash = "sha256-MJimcnYKujOL3FedGreNpuw1Jpg48ataDmFd1qwTS5A="; }; nativeCheckInputs = [ @@ -37,9 +39,6 @@ buildPythonPackage rec { allowing code to be developed that will work with both libraries. It was developed initially for the openpyxl project but is now a standalone module. - - The code was written by Elias Rabel as part of the Python - Düsseldorf openpyxl sprint in September 2014. ''; homepage = "https://foss.heptapod.net/openpyxl/et_xmlfile"; license = licenses.mit;