Files
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

76 lines
1.6 KiB
Nix

{
lib,
stdenv,
buildPythonPackage,
cryptography,
fetchFromGitHub,
mock,
pyparsing,
pytest-cov-stub,
pytest-forked,
pytest-randomly,
pytest-timeout,
pytestCheckHook,
pythonAtLeast,
six,
}:
buildPythonPackage rec {
pname = "httplib2";
version = "0.22.0";
format = "setuptools";
src = fetchFromGitHub {
owner = "httplib2";
repo = "httplib2";
rev = "v${version}";
hash = "sha256-76gdiRbF535CEaNXwNqsVeVc0dKglovMPQpGsOkbd/4=";
};
propagatedBuildInputs = [ pyparsing ];
nativeCheckInputs = [
cryptography
mock
pytest-cov-stub
pytest-forked
pytest-randomly
pytest-timeout
six
pytestCheckHook
];
__darwinAllowLocalNetworking = true;
# Don't run tests for older Pythons
doCheck = pythonAtLeast "3.9";
disabledTests = [
# ValueError: Unable to load PEM file.
# https://github.com/httplib2/httplib2/issues/192#issuecomment-993165140
"test_client_cert_password_verified"
# improper pytest marking
"test_head_301"
"test_303"
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# fails with "ConnectionResetError: [Errno 54] Connection reset by peer"
"test_connection_close"
# fails with HTTP 408 Request Timeout, instead of expected 200 OK
"test_timeout_subsequent"
"test_connection_close"
];
disabledTestPaths = [ "python2" ];
pythonImportsCheck = [ "httplib2" ];
meta = with lib; {
description = "Comprehensive HTTP client library";
homepage = "https://github.com/httplib2/httplib2";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}