python3Packages.greenplanet-energy-api: init at 0.1.8
Add a new Python package for the Green Planet Energy API library. This is an async Python library for querying the Green Planet Energy API. - Uses fetchFromGitHub with the latest v0.1.8 tag - Follows the finalAttrs pattern as per nixpkgs conventions - Maintainer: jamiemagee - All 25 test cases pass with 94% coverage
This commit is contained in:
@@ -0,0 +1,47 @@
|
||||
{
|
||||
lib,
|
||||
buildPythonPackage,
|
||||
fetchFromGitHub,
|
||||
setuptools,
|
||||
aiohttp,
|
||||
pytest-asyncio,
|
||||
pytest-cov,
|
||||
aioresponses,
|
||||
pytestCheckHook,
|
||||
}:
|
||||
|
||||
buildPythonPackage (finalAttrs: {
|
||||
pname = "greenplanet-energy-api";
|
||||
version = "0.1.8";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "petschni";
|
||||
repo = "greenplanet-energy-api";
|
||||
tag = "v${finalAttrs.version}";
|
||||
hash = "sha256-Ffmb4UUVfFhSNAy3Fq+3ERYSfD09JnrR8rKUV0sXjNI=";
|
||||
};
|
||||
|
||||
build-system = [ setuptools ];
|
||||
|
||||
dependencies = [
|
||||
aiohttp
|
||||
];
|
||||
|
||||
nativeCheckInputs = [
|
||||
pytest-asyncio
|
||||
pytest-cov
|
||||
aioresponses
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "greenplanet_energy_api" ];
|
||||
|
||||
meta = {
|
||||
description = "Async Python library for querying the Green Planet Energy API";
|
||||
homepage = "https://github.com/petschni/greenplanet-energy-api";
|
||||
changelog = "https://github.com/petschni/greenplanet-energy-api/releases/tag/${finalAttrs.src.tag}";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = [ lib.maintainers.jamiemagee ];
|
||||
};
|
||||
})
|
||||
@@ -6658,6 +6658,8 @@ self: super: with self; {
|
||||
# built-in for pypi
|
||||
greenlet = if isPyPy then null else callPackage ../development/python-modules/greenlet { };
|
||||
|
||||
greenplanet-energy-api = callPackage ../development/python-modules/greenplanet-energy-api { };
|
||||
|
||||
greenwavereality = callPackage ../development/python-modules/greenwavereality { };
|
||||
|
||||
gremlinpython = callPackage ../development/python-modules/gremlinpython { };
|
||||
|
||||
Reference in New Issue
Block a user