Skip to content

Commit

Permalink
Merge pull request #330438 from Sigmanificient/python-etcd
Browse files Browse the repository at this point in the history
python312Packages.python-etcd: 0.4.5 -> 0.5.0-unstable-2023-10-31; dr…
  • Loading branch information
emilazy authored Jul 28, 2024
2 parents 3979fe7 + e061d3e commit 6668b98
Showing 1 changed file with 28 additions and 21 deletions.
49 changes: 28 additions & 21 deletions pkgs/development/python-modules/python-etcd/default.nix
Original file line number Diff line number Diff line change
@@ -1,41 +1,48 @@
{
lib,
buildPythonPackage,
fetchPypi,
nose,
mock,
pyopenssl,
fetchFromGitHub,
setuptools,
urllib3,
dnspython,
pytestCheckHook,
etcd_3_4,
mock,
pyopenssl,
}:

buildPythonPackage rec {
buildPythonPackage {
pname = "python-etcd";
version = "0.4.5";
format = "setuptools";
version = "0.5.0-unstable-2023-10-31";
pyproject = true;

src = fetchPypi {
inherit pname version;
sha256 = "f1b5ebb825a3e8190494f5ce1509fde9069f2754838ed90402a8c11e1f52b8cb";
src = fetchFromGitHub {
owner = "jplana";
repo = "python-etcd";
rev = "5aea0fd4461bd05dd96e4ad637f6be7bceb1cee5";
hash = "sha256-eVirStLOPTbf860jfkNMWtGf+r0VygLZRjRDjBMCVKg=";
};

buildInputs = [
nose
mock
pyopenssl
];
build-system = [ setuptools ];

propagatedBuildInputs = [
dependencies = [
urllib3
dnspython
];

postPatch = ''
sed -i '19s/dns/"dnspython"/' setup.py
'';
nativeCheckInputs = [
pytestCheckHook
etcd_3_4
mock
pyopenssl
];

# Some issues with etcd not in path even though most tests passed
doCheck = false;
preCheck = ''
for file in "test_auth" "integration/test_simple"; do
substituteInPlace src/etcd/tests/$file.py \
--replace-fail "assertEquals" "assertEqual"
done
'';

meta = with lib; {
description = "Python client for Etcd";
Expand Down

0 comments on commit 6668b98

Please sign in to comment.