generated from nix-community/nur-packages-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flask-caching.nix
43 lines (37 loc) · 1.19 KB
/
flask-caching.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
{ lib
, python3
, fetchFromGitHub
}:
python3.pkgs.buildPythonApplication rec {
pname = "flask-caching";
version = "2.0.2";
#version = "2.0.2.2023.04.28";
format = "setuptools";
src = fetchFromGitHub {
owner = "pallets-eco";
repo = "flask-caching";
rev = "v${version}";
hash = "sha256-arGsLteTOaMQnryj6xsoIwql4HDutpL36cLsuG3Z3tc=";
# fix? ERROR: Could not find a version that satisfies the requirement Flask<3
# no
#rev = "7b1b2ce5ea940c870f45e6ca57232db028bfd475";
#hash = "sha256-TuG+61q2qMPhTAGJFdFlAPkJBDxZuUgCx/u6BkZSU7U=";
};
propagatedBuildInputs = with python3.pkgs; [
flask
cachelib
];
# fix: ERROR: Could not find a version that satisfies the requirement Flask<3
postPatch = ''
sed -i 's/"Flask < 3"/"Flask"/' setup.py
sed -i 's/"cachelib >= 0.9.0, < 0.10.0"/"cachelib"/' setup.py
'';
pythonImportsCheck = [ "flask_caching" ];
meta = with lib; {
description = "A caching extension for Flask";
homepage = "https://github.com/pallets-eco/flask-caching";
changelog = "https://github.com/pallets-eco/flask-caching/blob/${src.rev}/CHANGES.rst";
license = with licenses; [ ];
maintainers = with maintainers; [ ];
};
}