Merge pull request #217185 from fabaff/datadog-fix

python311Packages.datadog: disable failing tests on Python 3.11
This commit is contained in:
Jonas Heinrich 2023-02-20 12:17:07 +01:00 committed by GitHub
commit 23a1bd0af2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 45 additions and 30 deletions

View File

@ -1,18 +1,16 @@
{ lib
, buildPythonPackage
, fetchPypi
, pythonOlder
, hatchling
, decorator
, requests
, typing ? null
, configparser
, click
, fetchPypi
, freezegun
, hatchling
, mock
, pytestCheckHook
, pytest-vcr
, pytestCheckHook
, python-dateutil
, pythonAtLeast
, pythonOlder
, requests
, vcrpy
}:
@ -21,22 +19,20 @@ buildPythonPackage rec {
version = "0.44.0";
format = "pyproject";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "sha256-BxFw8MfvIlEdv3+b12xL5QDuLT1SBykApch7VJXSxzM=";
hash = "sha256-BxFw8MfvIlEdv3+b12xL5QDuLT1SBykApch7VJXSxzM=";
};
postPatch = ''
find . -name '*.pyc' -exec rm {} \;
'';
nativeBuildInputs = [
hatchling
];
propagatedBuildInputs = [ decorator requests ]
++ lib.optional (pythonOlder "3.5") typing
++ lib.optional (pythonOlder "3.0") configparser;
propagatedBuildInputs = [
requests
];
nativeCheckInputs = [
click
@ -54,13 +50,20 @@ buildPythonPackage rec {
disabledTests = [
"test_default_settings_set"
] ++ lib.optionals (pythonAtLeast "3.11") [
# https://github.com/DataDog/datadogpy/issues/746
"TestDogshell"
];
pythonImportsCheck = [ "datadog" ];
pythonImportsCheck = [
"datadog"
];
meta = with lib; {
description = "The Datadog Python library";
license = licenses.bsd3;
homepage = "https://github.com/DataDog/datadogpy";
changelog = "https://github.com/DataDog/datadogpy/blob/v${version}/CHANGELOG.md";
license = licenses.bsd3;
maintainers = with maintainers; [ ];
};
}

View File

@ -1,39 +1,51 @@
{ lib
, fetchPypi
, buildPythonPackage
, certifi
, chardet
, configparser
, datadog
, decorator
, fetchPypi
, idna
, requests
, python
, urllib3
, pythonOlder
}:
buildPythonPackage rec {
pname = "gradient_statsd";
pname = "gradient-statsd";
version = "1.0.1";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "iWlNX43ZtvU73wz4+8DgDulQNOnssJGxTBkvAaLj530=";
pname = "gradient_statsd";
inherit version;
hash = "sha256-iWlNX43ZtvU73wz4+8DgDulQNOnssJGxTBkvAaLj530=";
};
propagatedBuildInputs = [
certifi
chardet
datadog
decorator
idna
requests
]
++ lib.optional python.isPy2 configparser;
urllib3
];
pythonImportsCheck = [ "gradient_statsd" ];
pythonImportsCheck = [
"gradient_statsd"
];
# Pypi does not contain tests
doCheck = false;
meta = with lib; {
description = "Wrapper around the DogStatsd client";
homepage = "https://paperspace.com";
license = licenses.mit;
platforms = platforms.unix;
homepage = "https://paperspace.com";
license = licenses.mit;
maintainers = with maintainers; [ freezeboy ];
platforms = platforms.unix;
};
}