diff --git a/pkgs/development/python-modules/meshcore/default.nix b/pkgs/development/python-modules/meshcore/default.nix index 9d5a7330b5bb..0858e8f42a4f 100644 --- a/pkgs/development/python-modules/meshcore/default.nix +++ b/pkgs/development/python-modules/meshcore/default.nix @@ -2,31 +2,54 @@ lib, buildPythonPackage, fetchFromGitHub, + fetchpatch, + + # build-system hatchling, + # dependencies bleak, pycayennelpp, pyserial-asyncio-fast, + pycryptodome, + + # tests + pytest-asyncio, + pytestCheckHook, }: buildPythonPackage (finalAttrs: { pname = "meshcore"; - version = "2.2.8"; + version = "2.3.0"; pyproject = true; src = fetchFromGitHub { owner = "meshcore-dev"; repo = "meshcore_py"; tag = "v${finalAttrs.version}"; - hash = "sha256-S3hyA2TsgEHwB0gv5xFMTbwnAoGbceq0C5+8MBedD70="; + hash = "sha256-Vz2LQaP44Yojf9h2rSBvKRjW99IOj7C5MxqQnIUoIRE="; }; + patches = [ + (fetchpatch { + # https://github.com/meshcore-dev/meshcore_py/pull/71 + url = "https://github.com/meshcore-dev/meshcore_py/commit/9294e574739844e0e291b972b40e1a0a40149e47.patch"; + hash = "sha256-Ufr+5rDDO32W6dtD7wEU34iLJai3H0dBCEtLS5j4u/0="; + }) + ]; + build-system = [ hatchling ]; dependencies = [ bleak pycayennelpp pyserial-asyncio-fast + pycryptodome + ]; + + nativeCheckInputs = [ + pytest-asyncio + pytestCheckHook ]; pythonImportsCheck = [ "meshcore" ];