Merge pull request #159228 from fabaff/openevsewifi

This commit is contained in:
Martin Weinelt
2022-02-11 14:35:16 +01:00
committed by GitHub
3 changed files with 68 additions and 1 deletions
@@ -0,0 +1,65 @@
{ lib
, buildPythonPackage
, deprecated
, fetchFromGitHub
, fetchpatch
, poetry-core
, pytestCheckHook
, pythonOlder
, requests
, requests-mock
}:
buildPythonPackage rec {
pname = "openevsewifi";
version = "1.1.0";
format = "pyproject";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "miniconfig";
repo = "python-openevse-wifi";
rev = "v${version}";
sha256 = "sha256-pNm+zupBGijCXIkdanMk7nE/+SFvSEFp9/Ht5OoxQrU=";
};
nativeBuildInputs = [
poetry-core
];
propagatedBuildInputs = [
deprecated
requests
];
checkInputs = [
requests-mock
pytestCheckHook
];
patches = [
# Switch to poetry-core, https://github.com/miniconfig/python-openevse-wifi/pull/31
(fetchpatch {
name = "switch-to-poetry-core.patch";
url = "https://github.com/miniconfig/python-openevse-wifi/commit/1083868dd9f39a8ad7bb17f02cea1b8458e5b82d.patch";
sha256 = "sha256-XGeyi/PchBju1ICgL/ZCDGCbWwIJmLAcHuKaj+kDsI0=";
})
];
postPatch = ''
substituteInPlace pyproject.toml \
--replace 'pytest-cov = "^2.8.1"' ""
'';
pythonImportsCheck = [
"openevsewifi"
];
meta = with lib; {
description = "Module for communicating with the wifi module from OpenEVSE";
homepage = "https://github.com/miniconfig/python-openevse-wifi";
license = with licenses; [ mit ];
maintainers = with maintainers; [ fab ];
};
}
@@ -619,7 +619,7 @@
"openalpr_local" = ps: with ps; [ ];
"opencv" = ps: with ps; [ numpy ]; # missing inputs: opencv-python-headless
"openerz" = ps: with ps; [ openerz-api ];
"openevse" = ps: with ps; [ ]; # missing inputs: openevsewifi
"openevse" = ps: with ps; [ openevsewifi ];
"openexchangerates" = ps: with ps; [ ];
"opengarage" = ps: with ps; [ open-garage ];
"openhardwaremonitor" = ps: with ps; [ ];
+2
View File
@@ -5659,6 +5659,8 @@ in {
openerz-api = callPackage ../development/python-modules/openerz-api { };
openevsewifi = callPackage ../development/python-modules/openevsewifi { };
openhomedevice = callPackage ../development/python-modules/openhomedevice { };
openidc-client = callPackage ../development/python-modules/openidc-client { };