1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 setuptools,
6 wheel,
7 deprecation,
8 flask,
9 pydantic,
10 pytestCheckHook,
11 requests,
12 sanic,
13 sanic-testing,
14}:
15
16buildPythonPackage rec {
17 pname = "cloudevents";
18 version = "1.10.1";
19 pyproject = true;
20
21 src = fetchFromGitHub {
22 owner = "cloudevents";
23 repo = "sdk-python";
24 rev = "refs/tags/${version}";
25 hash = "sha256-YIvEAofWmnUblRd4jV3Zi3VdfocOnD05CMVm/abngyg=";
26 };
27
28 build-system = [
29 setuptools
30 wheel
31 ];
32
33 pythonImportsCheck = [ "cloudevents" ];
34
35 nativeCheckInputs = [
36 deprecation
37 flask
38 pydantic
39 pytestCheckHook
40 requests
41 sanic
42 sanic-testing
43 ];
44
45 disabledTestPaths = [ "samples/http-image-cloudevents/image_sample_test.py" ];
46
47 meta = with lib; {
48 description = "Python SDK for CloudEvents";
49 homepage = "https://github.com/cloudevents/sdk-python";
50 changelog = "https://github.com/cloudevents/sdk-python/blob/${src.rev}/CHANGELOG.md";
51 license = licenses.asl20;
52 maintainers = with maintainers; [ GaetanLepage ];
53 };
54}