2022-01-16 10:44:49 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, flask
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "flask-paranoid";
|
2022-04-02 16:47:34 +00:00
|
|
|
version = "0.3.0";
|
2022-01-16 10:44:49 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "miguelgrinberg";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2023-03-03 00:48:06 +00:00
|
|
|
hash = "sha256-tikD8efc3Q3xIQnaC3SSBaCRQxMI1HzXxeupvYeNnE4=";
|
2022-01-16 10:44:49 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
postPatch = ''
|
|
|
|
# tests have a typo in one of the assertions
|
|
|
|
substituteInPlace tests/test_paranoid.py --replace "01-Jan-1970" "01 Jan 1970"
|
|
|
|
'';
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
flask
|
|
|
|
];
|
|
|
|
|
2023-01-21 12:00:00 +00:00
|
|
|
nativeCheckInputs = [
|
2022-01-16 10:44:49 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "flask_paranoid" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/miguelgrinberg/flask-paranoid/";
|
|
|
|
description = "Simple user session protection";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ gador ];
|
|
|
|
};
|
|
|
|
}
|