2021-12-06 16:07:01 +00:00
|
|
|
{ lib
|
|
|
|
, atpublic
|
|
|
|
, attrs
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pytest-mock
|
|
|
|
, pytestCheckHook
|
|
|
|
, pythonOlder
|
2024-05-15 15:35:15 +00:00
|
|
|
, setuptools
|
2021-12-06 16:07:01 +00:00
|
|
|
, typing-extensions
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aiosmtpd";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "1.4.5";
|
2024-05-15 15:35:15 +00:00
|
|
|
pyproject = true;
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "aio-libs";
|
2024-05-15 15:35:15 +00:00
|
|
|
repo = "aiosmtpd";
|
2024-04-21 15:54:59 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-8nQ4BVSLYgZHRGkbujy/olV/+GABlkDhe5wef3hyQpQ=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools
|
|
|
|
];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
propagatedBuildInputs = [
|
2021-12-06 16:07:01 +00:00
|
|
|
atpublic
|
|
|
|
attrs
|
|
|
|
] ++ lib.optionals (pythonOlder "3.8") [
|
|
|
|
typing-extensions
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2021-12-06 16:07:01 +00:00
|
|
|
pytest-mock
|
|
|
|
pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2022-02-20 05:27:41 +00:00
|
|
|
# Fixes for Python 3.10 can't be applied easily, https://github.com/aio-libs/aiosmtpd/pull/294
|
|
|
|
doCheck = pythonOlder "3.10";
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
disabledTests = [
|
|
|
|
# Requires git
|
|
|
|
"test_ge_master"
|
|
|
|
# Seems to be a sandbox issue
|
|
|
|
"test_byclient"
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"aiosmtpd"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Asyncio based SMTP server";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "aiosmtpd";
|
2021-12-06 16:07:01 +00:00
|
|
|
homepage = "https://aiosmtpd.readthedocs.io/";
|
2024-05-15 15:35:15 +00:00
|
|
|
changelog = "https://github.com/aio-libs/aiosmtpd/releases/tag/v${version}";
|
2020-04-24 23:36:52 +00:00
|
|
|
longDescription = ''
|
|
|
|
This is a server for SMTP and related protocols, similar in utility to the
|
2021-12-06 16:07:01 +00:00
|
|
|
standard library's smtpd.py module.
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ eadwu ];
|
|
|
|
};
|
|
|
|
}
|