Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 buildPythonPackage, 6 7 # build-system 8 hatchling, 9 10 # dependencies 11 click, 12 redis, 13 14 # tests 15 addBinToPathHook, 16 psutil, 17 pytestCheckHook, 18 redisTestHook, 19 versionCheckHook, 20}: 21 22buildPythonPackage rec { 23 pname = "rq"; 24 version = "2.4"; 25 pyproject = true; 26 27 src = fetchFromGitHub { 28 owner = "rq"; 29 repo = "rq"; 30 tag = "v${version}"; 31 hash = "sha256-7aq9JeyM+IjlRPgh4gs1DmkF0hU5EasgTuUPPlf8960="; 32 }; 33 34 build-system = [ hatchling ]; 35 36 dependencies = [ 37 click 38 redis 39 ]; 40 41 nativeCheckInputs = [ 42 addBinToPathHook 43 psutil 44 pytestCheckHook 45 redisTestHook 46 versionCheckHook 47 ]; 48 versionCheckProgramArg = "--version"; 49 50 __darwinAllowLocalNetworking = true; 51 52 disabledTests = lib.optionals stdenv.hostPlatform.isDarwin [ 53 # PermissionError: [Errno 13] Permission denied: '/tmp/rq-tests.txt' 54 "test_deleted_jobs_arent_executed" 55 "test_suspend_worker_execution" 56 ]; 57 58 pythonImportsCheck = [ "rq" ]; 59 60 meta = { 61 description = "Library for creating background jobs and processing them"; 62 homepage = "https://github.com/nvie/rq/"; 63 changelog = "https://github.com/rq/rq/releases/tag/${src.tag}"; 64 license = lib.licenses.bsd2; 65 maintainers = with lib.maintainers; [ mrmebelman ]; 66 }; 67}