1{ 2 lib, 3 aiohttp, 4 aioresponses, 5 buildPythonPackage, 6 fetchFromGitHub, 7 poetry-core, 8 pytest-asyncio, 9 pytest-cov-stub, 10 pytestCheckHook, 11 pythonOlder, 12 syrupy, 13 yarl, 14}: 15 16buildPythonPackage rec { 17 pname = "aiowithings"; 18 version = "3.1.6"; 19 pyproject = true; 20 21 disabled = pythonOlder "3.11"; 22 23 src = fetchFromGitHub { 24 owner = "joostlek"; 25 repo = "python-withings"; 26 tag = "v${version}"; 27 hash = "sha256-YC1rUyPXWbJ/xfUus5a7vw44gw7PIAdwhrUstXB/+nI="; 28 }; 29 30 build-system = [ poetry-core ]; 31 32 dependencies = [ 33 aiohttp 34 yarl 35 ]; 36 37 nativeCheckInputs = [ 38 aioresponses 39 pytest-asyncio 40 pytest-cov-stub 41 pytestCheckHook 42 syrupy 43 ]; 44 45 pythonImportsCheck = [ "aiowithings" ]; 46 47 pytestFlags = [ "--snapshot-update" ]; 48 49 disabledTests = [ 50 # Tests require network access 51 "test_creating_own_session" 52 "test_error_codes" 53 "test_get_activities" 54 "test_get_devices" 55 "test_get_goals" 56 "test_get_measurement" 57 "test_get_new_device" 58 "test_get_sleep_summary" 59 "test_get_sleep" 60 "test_get_workouts" 61 "test_list_all_subscriptions" 62 "test_list_subscriptions" 63 "test_putting_in_own_session" 64 "test_revoking" 65 "test_subscribing" 66 "test_timeout" 67 "test_unexpected_server_response" 68 ]; 69 70 meta = with lib; { 71 description = "Module to interact with Withings"; 72 homepage = "https://github.com/joostlek/python-withings"; 73 changelog = "https://github.com/joostlek/python-withings/releases/tag/v${version}"; 74 license = licenses.mit; 75 maintainers = with maintainers; [ fab ]; 76 }; 77}