1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 fetchpatch,
6 pyopenssl,
7 pytestCheckHook,
8}:
9
10buildPythonPackage rec {
11 pname = "aiosasl";
12 version = "0.5.0";
13
14 format = "setuptools";
15
16 src = fetchFromGitHub {
17 owner = "horazont";
18 repo = "aiosasl";
19 rev = "refs/tags/v${version}";
20 hash = "sha256-JIuNPb/l4QURMQc905H2iNGCfMz+zM/QJhDQOR8LPdc=";
21 };
22
23 patches = [
24 (fetchpatch {
25 name = "python311-compat.patch";
26 url = "https://github.com/horazont/aiosasl/commit/44c48d36b416bd635d970dba2607a31b2167ea1b.patch";
27 hash = "sha256-u6PJKV54dU2MA9hXa/9hJ3eLVds1DuLHGbt8y/OakWs=";
28 })
29 ];
30
31 nativeCheckInputs = [
32 pyopenssl
33 pytestCheckHook
34 ];
35
36 pythonImportsCheck = [ "aiosasl" ];
37
38 meta = {
39 description = "Asyncio SASL library";
40 homepage = "https://github.com/horazont/aiosasl";
41 license = lib.licenses.lgpl3Plus;
42 maintainers = with lib.maintainers; [ dotlambda ];
43 };
44}