python312Packages.asgi-lifespan: init at 2.1.0

Programmatic startup/shutdown of ASGI apps

https://github.com/florimondmanca/asgi-lifespan
This commit is contained in:
Fabian Affolter 2024-03-28 13:56:35 +01:00
parent 4efe48318b
commit e9fc5be0c7
2 changed files with 53 additions and 0 deletions

View File

@ -0,0 +1,51 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, pythonOlder
, setuptools
, setuptools-scm
, sniffio
}:
buildPythonPackage rec {
pname = "asgi-lifespan";
version = "2.1.0";
pyproject = true;
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "florimondmanca";
repo = "asgi-lifespan";
rev = "refs/tags/${version}";
hash = "sha256-Jgmd/4c1lxHM/qi3MJNN1aSSUJrI7CRNwwHrFwwcCkc=";
};
postPatch = ''
sed -i "/--cov/d" setup.cfg
'';
build-system = [
setuptools
setuptools-scm
];
dependencies = [
sniffio
];
# Circular dependencies, starlette
doCheck = false;
pythonImportsCheck = [
"asgi_lifespan"
];
meta = with lib; {
description = "Programmatic startup/shutdown of ASGI apps";
homepage = "https://github.com/florimondmanca/asgi-lifespan";
changelog = "https://github.com/florimondmanca/asgi-lifespan/blob/${version}/CHANGELOG.md";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}

View File

@ -783,6 +783,8 @@ self: super: with self; {
asgi-csrf = callPackage ../development/python-modules/asgi-csrf { };
asgi-lifespan = callPackage ../development/python-modules/asgi-lifespan { };
asgi-logger = callPackage ../development/python-modules/asgi-logger { };
asgineer = callPackage ../development/python-modules/asgineer { };