Merge pull request #135039 from fabaff/fix-whisper

This commit is contained in:
Sandro 2021-08-21 20:07:10 +02:00 committed by GitHub
commit 60c1c19ece
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 66 additions and 15 deletions

View file

@ -1,19 +1,40 @@
{ lib, buildPythonPackage, fetchPypi, mock, six }:
{ lib
, buildPythonPackage
, fetchFromGitHub
, mock
, six
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "whisper";
version = "1.1.8";
src = fetchPypi {
inherit pname version;
sha256 = "345f35d0dccaf181e0aa4353e6c13f40f5cceda10a3c7021dafab29f004f62ae";
src = fetchFromGitHub {
owner = "graphite-project";
repo = pname;
rev = version;
sha256 = "11f7sarj62zgpw3ak4a2q55lj7ap4039l9ybc3a6yvs1ppvrcn7x";
};
propagatedBuildInputs = [ six ];
checkInputs = [ mock ];
propagatedBuildInputs = [
six
];
checkInputs = [
mock
pytestCheckHook
];
disabledTests = [
# whisper-resize.py: not found
"test_resize_with_aggregate"
];
pythonImportsCheck = [ "whisper" ];
meta = with lib; {
homepage = "http://graphite.wikidot.com/";
homepage = "https://github.com/graphite-project/whisper";
description = "Fixed size round-robin style database";
maintainers = with maintainers; [ offline basvandijk ];
license = licenses.asl20;

View file

@ -1,21 +1,51 @@
{ lib, fetchPypi, buildPythonPackage, isPy27 }:
{ lib
, brotli
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
, pythonOlder
, requests
}:
buildPythonPackage rec {
pname = "whitenoise";
version = "5.2.0";
disabled = isPy27;
version = "5.3.0";
disabled = pythonOlder "3.5";
src = fetchPypi {
inherit pname version;
sha256 = "05ce0be39ad85740a78750c86a93485c40f08ad8c62a6006de0233765996e5c7";
src = fetchFromGitHub {
owner = "evansd";
repo = pname;
rev = "v${version}";
sha256 = "17j1rml1hb43c7fs7kf4ygkpmnjppzgsbnyw3plq9w3yh9w5hkhg";
};
# No tests
doCheck = false;
propagatedBuildInputs = [
brotli
];
checkInputs = [
pytestCheckHook
requests
];
disabledTestPaths = [
# Don't run Django tests
"tests/test_django_whitenoise.py"
"tests/test_runserver_nostatic.py"
"tests/test_storage.py"
];
disabledTests = [
# Test fails with AssertionError
"test_modified"
];
pythonImportsCheck = [ "whitenoise" ];
meta = with lib; {
description = "Radically simplified static file serving for WSGI applications";
homepage = "http://whitenoise.evans.io/";
license = licenses.mit;
maintainers = with maintainers; [ ];
};
}