2024-05-15 15:35:15 +00:00
|
|
|
{
|
|
|
|
lib,
|
2024-09-19 14:19:46 +00:00
|
|
|
aiodns,
|
2024-05-15 15:35:15 +00:00
|
|
|
aiofiles,
|
|
|
|
aiohttp-socks,
|
2024-09-19 14:19:46 +00:00
|
|
|
aiohttp,
|
2024-05-15 15:35:15 +00:00
|
|
|
aresponses,
|
|
|
|
babel,
|
|
|
|
buildPythonPackage,
|
|
|
|
certifi,
|
|
|
|
fetchFromGitHub,
|
|
|
|
gitUpdater,
|
|
|
|
hatchling,
|
|
|
|
magic-filter,
|
2024-06-20 14:57:18 +00:00
|
|
|
motor,
|
2024-05-15 15:35:15 +00:00
|
|
|
pycryptodomex,
|
|
|
|
pydantic,
|
2024-06-20 14:57:18 +00:00
|
|
|
pymongo,
|
2024-05-15 15:35:15 +00:00
|
|
|
pytest-aiohttp,
|
|
|
|
pytest-asyncio,
|
|
|
|
pytest-lazy-fixture,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
pytz,
|
|
|
|
redis,
|
2024-09-19 14:19:46 +00:00
|
|
|
uvloop,
|
2023-08-04 22:07:22 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aiogram";
|
2024-09-26 11:04:55 +00:00
|
|
|
version = "3.13.1";
|
2024-01-13 08:15:51 +00:00
|
|
|
pyproject = true;
|
2023-08-04 22:07:22 +00:00
|
|
|
|
2024-02-29 20:09:43 +00:00
|
|
|
disabled = pythonOlder "3.8";
|
2023-08-04 22:07:22 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "aiogram";
|
|
|
|
repo = "aiogram";
|
2023-11-16 04:20:00 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-09-26 11:04:55 +00:00
|
|
|
hash = "sha256-uTFh1ncIPF9SmAEVGeBnXEKrYzgifZan1sxk5UiG92U=";
|
2023-08-04 22:07:22 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
build-system = [ hatchling ];
|
2024-04-21 15:54:59 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
dependencies = [
|
2024-01-13 08:15:51 +00:00
|
|
|
aiofiles
|
2023-08-04 22:07:22 +00:00
|
|
|
aiohttp
|
|
|
|
certifi
|
|
|
|
magic-filter
|
2024-01-13 08:15:51 +00:00
|
|
|
pydantic
|
2023-08-04 22:07:22 +00:00
|
|
|
];
|
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
optional-dependencies = {
|
|
|
|
fast = [
|
|
|
|
aiodns
|
|
|
|
uvloop
|
|
|
|
];
|
|
|
|
mongo = [
|
|
|
|
motor
|
|
|
|
pymongo
|
|
|
|
];
|
|
|
|
redis = [ redis ];
|
|
|
|
proxy = [ aiohttp-socks ];
|
|
|
|
i18n = [ babel ];
|
|
|
|
};
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
nativeCheckInputs = [
|
|
|
|
aresponses
|
2024-04-21 15:54:59 +00:00
|
|
|
pycryptodomex
|
|
|
|
pytest-aiohttp
|
2023-08-04 22:07:22 +00:00
|
|
|
pytest-asyncio
|
|
|
|
pytest-lazy-fixture
|
|
|
|
pytestCheckHook
|
2024-01-13 08:15:51 +00:00
|
|
|
pytz
|
2024-09-19 14:19:46 +00:00
|
|
|
] ++ lib.flatten (builtins.attrValues optional-dependencies);
|
2023-08-04 22:07:22 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
pytestFlagsArray = [
|
2024-05-15 15:35:15 +00:00
|
|
|
"-W"
|
|
|
|
"ignore::pluggy.PluggyTeardownRaisedWarning"
|
|
|
|
"-W"
|
|
|
|
"ignore::pytest.PytestDeprecationWarning"
|
|
|
|
"-W"
|
|
|
|
"ignore::DeprecationWarning"
|
2023-10-09 19:29:22 +00:00
|
|
|
];
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
pythonImportsCheck = [ "aiogram" ];
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
passthru.updateScript = gitUpdater { rev-prefix = "v"; };
|
2024-01-13 08:15:51 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Modern and fully asynchronous framework for Telegram Bot API";
|
|
|
|
homepage = "https://github.com/aiogram/aiogram";
|
|
|
|
changelog = "https://github.com/aiogram/aiogram/releases/tag/v${version}";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ sikmir ];
|
|
|
|
};
|
|
|
|
}
|