nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 59 lines 1.3 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 poetry-core, 6 aw-core, 7 requests, 8 persist-queue, 9 click, 10 tabulate, 11 typing-extensions, 12 pytestCheckHook, 13}: 14 15buildPythonPackage rec { 16 pname = "aw-client"; 17 version = "0.5.15"; 18 pyproject = true; 19 20 src = fetchFromGitHub { 21 owner = "ActivityWatch"; 22 repo = "aw-client"; 23 tag = "v${version}"; 24 hash = "sha256-AS29DIfEQ6/vh8idcMMQoGmiRM8MMf3eVQzvNPsXgpA="; 25 }; 26 27 build-system = [ poetry-core ]; 28 29 dependencies = [ 30 aw-core 31 requests 32 persist-queue 33 click 34 tabulate 35 typing-extensions 36 ]; 37 38 nativeCheckInputs = [ pytestCheckHook ]; 39 40 # Only run this test, the others are integration tests that require 41 # an instance of aw-server running in order to function. 42 enabledTestPaths = [ "tests/test_requestqueue.py" ]; 43 44 preCheck = '' 45 # Fake home folder for tests that write to $HOME 46 export HOME="$TMPDIR" 47 ''; 48 49 pythonImportsCheck = [ "aw_client" ]; 50 51 meta = { 52 description = "Client library for ActivityWatch"; 53 homepage = "https://github.com/ActivityWatch/aw-client"; 54 changelog = "https://github.com/ActivityWatch/aw-client/releases/tag/v${version}"; 55 license = lib.licenses.mpl20; 56 maintainers = with lib.maintainers; [ huantian ]; 57 mainProgram = "aw-client"; 58 }; 59}