1{
2 lib,
3 buildPythonPackage,
4 pythonOlder,
5 fetchPypi,
6 hatchling,
7 scim2-models,
8 pytestCheckHook,
9 portpicker,
10 pytest-httpserver,
11 pytest-asyncio,
12 scim2-server,
13 httpx,
14 werkzeug,
15 cacert,
16}:
17
18buildPythonPackage rec {
19 pname = "scim2-client";
20 version = "0.5.1";
21
22 pyproject = true;
23
24 disabled = pythonOlder "3.9";
25
26 src = fetchPypi {
27 inherit version;
28 pname = "scim2_client";
29 hash = "sha256-g2RR+Ruvjw88cGHcwEPoktTmB8VcWAPnea3BErS8JyI=";
30 };
31
32 build-system = [ hatchling ];
33
34 dependencies = [ scim2-models ];
35
36 nativeCheckInputs = [
37 pytestCheckHook
38 portpicker
39 pytest-httpserver
40 pytest-asyncio
41 scim2-server
42 werkzeug
43 cacert
44 ] ++ optional-dependencies.httpx;
45
46 # Werkzeug returns 500, didn't deem it worth it to investigate
47 disabledTests = [
48 "test_search_request"
49 "test_query_dont_check_request_payload"
50 ];
51
52 pythonImportsCheck = [ "scim2_client" ];
53
54 optional-dependencies = {
55 httpx = [ httpx ];
56 werkzeug = [ werkzeug ];
57 };
58
59 meta = with lib; {
60 description = "Pythonically build SCIM requests and parse SCIM responses";
61 homepage = "https://scim2-client.readthedocs.io/";
62 changelog = "https://github.com/python-scim/scim2-client/releases/tag/${version}";
63 license = licenses.asl20;
64 maintainers = with maintainers; [ erictapen ];
65 };
66}