depot/third_party/nixpkgs/pkgs/development/python-modules/aioelectricitymaps/default.nix
Default email 587713944a Project import generated by Copybara.
GitOrigin-RevId: 6143fc5eeb9c4f00163267708e26191d1e918932
2024-04-21 17:54:59 +02:00

62 lines
1.1 KiB
Nix

{ lib
, aiohttp
, aioresponses
, buildPythonPackage
, fetchFromGitHub
, mashumaro
, orjson
, poetry-core
, pytest-asyncio
, pytestCheckHook
, pythonOlder
, syrupy
}:
buildPythonPackage rec {
pname = "aioelectricitymaps";
version = "1.0.0";
pyproject = true;
disabled = pythonOlder "3.11";
src = fetchFromGitHub {
owner = "jpbede";
repo = "aioelectricitymaps";
rev = "refs/tags/v${version}";
hash = "sha256-l6D5Cr2d89n+Ac5V5geBUY0sOiEO3sci9244K0MI+dc=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-warn "--cov" ""
'';
nativeBuildInputs = [
poetry-core
];
propagatedBuildInputs = [
aiohttp
mashumaro
orjson
];
nativeCheckInputs = [
aioresponses
pytest-asyncio
pytestCheckHook
syrupy
];
pythonImportsCheck = [
"aioelectricitymaps"
];
meta = with lib; {
description = "Module for interacting with Electricity maps";
homepage = "https://github.com/jpbede/aioelectricitymaps";
changelog = "https://github.com/jpbede/aioelectricitymaps/releases/tag/v${version}";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}