1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 buildPythonPackage, 6 7 # build-system 8 flit-core, 9 10 # dependencies 11 flask, 12 cachelib, 13 msgspec, 14 15 # tests 16 boto3, 17 flask-sqlalchemy, 18 memcachedTestHook, 19 pytestCheckHook, 20 redis, 21 redisTestHook, 22 pymongo, 23 pymemcache, 24 python-memcached, 25}: 26 27buildPythonPackage rec { 28 pname = "flask-session"; 29 version = "0.8.0"; 30 pyproject = true; 31 32 src = fetchFromGitHub { 33 owner = "pallets-eco"; 34 repo = "flask-session"; 35 tag = version; 36 hash = "sha256-QLtsM0MFgZbuLJPLc5/mUwyYc3bYxildNKNxOF8Z/3Y="; 37 }; 38 39 build-system = [ flit-core ]; 40 41 dependencies = [ 42 cachelib 43 flask 44 msgspec 45 ]; 46 47 nativeCheckInputs = [ 48 flask-sqlalchemy 49 memcachedTestHook 50 pytestCheckHook 51 redis 52 redisTestHook 53 pymongo 54 pymemcache 55 python-memcached 56 boto3 57 ]; 58 59 disabledTests = [ 60 # unfree 61 "test_mongo_default" 62 ]; 63 64 disabledTestPaths = [ "tests/test_dynamodb.py" ]; 65 66 pythonImportsCheck = [ "flask_session" ]; 67 68 __darwinAllowLocalNetworking = true; 69 70 # Hang indefinitely 71 doCheck = !(stdenv.hostPlatform.isDarwin && stdenv.hostPlatform.isx86_64); 72 73 meta = { 74 description = "Flask extension that adds support for server-side sessions"; 75 homepage = "https://github.com/pallets-eco/flask-session"; 76 changelog = "https://github.com/pallets-eco/flask-session/releases/tag/${version}"; 77 license = lib.licenses.bsd3; 78 maintainers = with lib.maintainers; [ zhaofengli ]; 79 }; 80}