git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #118944 from fabaff/homematicip

python3Packages.homematicip: init at 1.0.0

commit8735fd1e95e8fc48e8d362f5ddbc9c953cb06197 authorMartin Weinelt <mweinelt@users.noreply.github.com> dateSat 10 Apr 2021, 02:19 (6 years ago) parent27693c7793d671
5 files changed+120−1
pkgs/development/python-modules/aiohttp-wsgi/default.nix+37 pkgs/development/python-modules/homematicip/default.nix+77 pkgs/servers/home-assistant/component-packages.nix+1−1 pkgs/servers/home-assistant/default.nix+1 pkgs/top-level/python-packages.nix+4
pkgs/development/python-modules/aiohttp-wsgi/default.nixnew file+37
@@ -0,0 +1,37 @@
1+{ lib
2+, aiohttp
3+, buildPythonPackage
4+, fetchFromGitHub
5+, pytestCheckHook
6+, pythonOlder
7+}:
8+
9+buildPythonPackage rec {
10+ pname = "aiohttp-wsgi";
11+ version = "0.8.2";
12+ disabled = pythonOlder "3.6";
13+
14+ src = fetchFromGitHub {
15+ owner = "etianen";
16+ repo = pname;
17+ rev = version;
18+ sha256 = "0wirn3xqxxgkpy5spicd7p1bkdnsrch61x2kcpdwpixmx961pq7x";
19+ };
20+
21+ propagatedBuildInputs = [
22+ aiohttp
23+ ];
24+
25+ checkInputs = [
26+ pytestCheckHook
27+ ];
28+
29+ pythonImportsCheck = [ "aiohttp_wsgi" ];
30+
31+ meta = with lib; {
32+ description = "WSGI adapter for aiohttp";
33+ homepage = "https://github.com/etianen/aiohttp-wsgi";
34+ license = with licenses; [ bsd3 ];
35+ maintainers = with maintainers; [ fab ];
36+ };
37+}
pkgs/development/python-modules/homematicip/default.nixnew file+77
@@ -0,0 +1,77 @@
1+{ lib
2+, aenum
3+, aiohttp
4+, aiohttp-wsgi
5+, async-timeout
6+, buildPythonPackage
7+, fetchFromGitHub
8+, pytestCheckHook
9+, pythonOlder
10+, pytest-aiohttp
11+, pytest-asyncio
12+, requests
13+, websocket_client
14+, websockets
15+}:
16+
17+buildPythonPackage rec {
18+ pname = "homematicip";
19+ version = "1.0.0";
20+ disabled = pythonOlder "3.6";
21+
22+ src = fetchFromGitHub {
23+ owner = "coreGreenberet";
24+ repo = "homematicip-rest-api";
25+ rev = version;
26+ sha256 = "0bgvrjcf10kiqqkbl56sxx3jydd722b08q2j9c8sxpk0qdrmrinv";
27+ };
28+
29+ propagatedBuildInputs = [
30+ aenum
31+ aiohttp
32+ async-timeout
33+ requests
34+ websocket_client
35+ websockets
36+ ];
37+
38+ checkInputs = [
39+ aiohttp-wsgi
40+ pytest-aiohttp
41+ pytest-asyncio
42+ pytestCheckHook
43+ ];
44+
45+ disabledTests = [
46+ # Assert issues with datetime
47+ "test_contact_interface_device"
48+ "test_dimmer"
49+ "test_heating_failure_alert_group"
50+ "test_heating"
51+ "test_humidity_warning_rule_group"
52+ "test_meta_group"
53+ "test_pluggable_switch_measuring"
54+ "test_rotary_handle_sensor"
55+ "test_security_group"
56+ "test_shutter_device"
57+ "test_smoke_detector"
58+ "test_switching_group"
59+ "test_temperature_humidity_sensor_outdoor"
60+ "test_wall_mounted_thermostat_pro"
61+ "test_weather_sensor"
62+ # Random failures
63+ "test_home_getSecurityJournal"
64+ "test_home_unknown_types"
65+ # Requires network access
66+ "test_websocket"
67+ ];
68+
69+ pythonImportsCheck = [ "homematicip" ];
70+
71+ meta = with lib; {
72+ description = "Python module for the homematicIP REST API";
73+ homepage = "https://github.com/coreGreenberet/homematicip-rest-api";
74+ license = with licenses; [ gpl3Only ];
75+ maintainers = with maintainers; [ fab ];
76+ };
77+}
pkgs/servers/home-assistant/component-packages.nix+1−1
@@ -357,7 +357,7 @@
357357 "homekit" = ps: with ps; [ HAP-python pyqrcode pyturbojpeg aiohttp-cors base36 fnvhash ha-ffmpeg zeroconf ];
358358 "homekit_controller" = ps: with ps; [ aiohomekit aiohttp-cors zeroconf ];
359359 "homematic" = ps: with ps; [ pyhomematic ];
360− "homematicip_cloud" = ps: with ps; [ ]; # missing inputs: homematicip
360+ "homematicip_cloud" = ps: with ps; [ homematicip ];
361361 "homeworks" = ps: with ps; [ ]; # missing inputs: pyhomeworks
362362 "honeywell" = ps: with ps; [ ]; # missing inputs: somecomfort
363363 "horizon" = ps: with ps; [ ]; # missing inputs: horimote
pkgs/servers/home-assistant/default.nix+1
@@ -241,6 +241,7 @@ in with py.pkgs; buildPythonApplication rec {
241241 "homekit_controller"
242242 "homeassistant"
243243 "homematic"
244+ "homematicip_cloud"
244245 "html5"
245246 "http"
246247 "hue"
pkgs/top-level/python-packages.nix+4
@@ -279,6 +279,8 @@ in {
279279
280280 aiohttp-swagger = callPackage ../development/python-modules/aiohttp-swagger { };
281281
282+ aiohttp-wsgi = callPackage ../development/python-modules/aiohttp-wsgi { };
283+
282284 aioitertools = callPackage ../development/python-modules/aioitertools { };
283285
284286 aiobotocore = callPackage ../development/python-modules/aiobotocore { };
@@ -3127,6 +3129,8 @@ in {
31273129
31283130 homeassistant-pyozw = callPackage ../development/python-modules/homeassistant-pyozw { };
31293131
3132+ homematicip = callPackage ../development/python-modules/homematicip { };
3133+
31303134 homepluscontrol = callPackage ../development/python-modules/homepluscontrol { };
31313135
31323136 hoomd-blue = toPythonModule (callPackage ../development/python-modules/hoomd-blue {