python311Packages.bleak: fix bluetoothctl substitution

This commit is contained in:
Martin Weinelt
2023-10-21 14:59:07 +02:00
parent 862bdb6435
commit 21317d93e1
@@ -25,6 +25,12 @@ buildPythonPackage rec {
hash = "sha256-T0im8zKyNLbskAEDeUUFS/daJtvttlHlttjscqP8iSk=";
};
postPatch = ''
# bleak checks BlueZ's version with a call to `bluetoothctl --version`
substituteInPlace bleak/backends/bluezdbus/version.py \
--replace \"bluetoothctl\" \"${bluez}/bin/bluetoothctl\"
'';
nativeBuildInputs = [
poetry-core
];
@@ -40,12 +46,6 @@ buildPythonPackage rec {
pytestCheckHook
];
postPatch = ''
# bleak checks BlueZ's version with a call to `bluetoothctl --version`
substituteInPlace bleak/backends/bluezdbus/__init__.py \
--replace \"bluetoothctl\" \"${bluez}/bin/bluetoothctl\"
'';
pythonImportsCheck = [
"bleak"
];