depot/third_party/nixpkgs/pkgs/development/python-modules/bluetooth-sensor-state-data/default.nix
Default email f34ce41345 Project import generated by Copybara.
GitOrigin-RevId: b73c2221a46c13557b1b3be9c2070cc42cf01eb3
2024-07-27 08:49:29 +02:00

49 lines
1.2 KiB
Nix

{
lib,
buildPythonPackage,
fetchFromGitHub,
home-assistant-bluetooth,
poetry-core,
pytestCheckHook,
pythonOlder,
sensor-state-data,
}:
buildPythonPackage rec {
pname = "bluetooth-sensor-state-data";
version = "1.7.1";
pyproject = true;
disabled = pythonOlder "3.9";
src = fetchFromGitHub {
owner = "Bluetooth-Devices";
repo = "bluetooth-sensor-state-data";
rev = "refs/tags/v${version}";
hash = "sha256-Gsg6Gbb+nvrKr7vn9zUuPTPtSjqFJyMk7oLt7LUUn5A=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail " --cov=bluetooth_sensor_state_data --cov-report=term-missing:skip-covered" ""
'';
build-system = [ poetry-core ];
dependencies = [
home-assistant-bluetooth
sensor-state-data
];
nativeCheckInputs = [ pytestCheckHook ];
pythonImportsCheck = [ "bluetooth_sensor_state_data" ];
meta = with lib; {
description = "Models for storing and converting Bluetooth Sensor State Data";
homepage = "https://github.com/bluetooth-devices/bluetooth-sensor-state-data";
changelog = "https://github.com/Bluetooth-Devices/bluetooth-sensor-state-data/releases/tag/v${version}";
license = licenses.asl20;
maintainers = with maintainers; [ fab ];
};
}