metal-stack-api 0.0.38__py3-none-any.whl → 0.0.40__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. {metal_stack_api-0.0.38.dist-info → metal_stack_api-0.0.40.dist-info}/METADATA +3 -3
  2. metal_stack_api-0.0.40.dist-info/RECORD +108 -0
  3. {metal_stack_api-0.0.38.dist-info → metal_stack_api-0.0.40.dist-info}/WHEEL +1 -1
  4. metalstack/admin/v2/filesystem_connect.py +8 -7
  5. metalstack/admin/v2/filesystem_pb2.py +3 -3
  6. metalstack/admin/v2/image_connect.py +9 -8
  7. metalstack/admin/v2/image_pb2.py +3 -3
  8. metalstack/admin/v2/ip_connect.py +6 -5
  9. metalstack/admin/v2/ip_pb2.py +3 -3
  10. metalstack/admin/v2/machine_connect.py +7 -6
  11. metalstack/admin/v2/machine_pb2.py +3 -3
  12. metalstack/admin/v2/network_connect.py +10 -9
  13. metalstack/admin/v2/network_pb2.py +3 -3
  14. metalstack/admin/v2/partition_connect.py +9 -8
  15. metalstack/admin/v2/partition_pb2.py +3 -3
  16. metalstack/admin/v2/project_connect.py +6 -5
  17. metalstack/admin/v2/project_pb2.py +3 -3
  18. metalstack/admin/v2/size_connect.py +8 -7
  19. metalstack/admin/v2/size_pb2.py +3 -3
  20. metalstack/admin/v2/switch_connect.py +11 -10
  21. metalstack/admin/v2/switch_pb2.py +21 -21
  22. metalstack/admin/v2/switch_pb2.pyi +2 -4
  23. metalstack/admin/v2/tenant_connect.py +7 -6
  24. metalstack/admin/v2/tenant_pb2.py +3 -3
  25. metalstack/admin/v2/token_connect.py +8 -7
  26. metalstack/admin/v2/token_pb2.py +3 -3
  27. metalstack/admin/v2/vpn_connect.py +7 -6
  28. metalstack/admin/v2/vpn_pb2.py +17 -14
  29. metalstack/admin/v2/vpn_pb2.pyi +13 -4
  30. metalstack/api/v2/common_pb2.py +3 -3
  31. metalstack/api/v2/filesystem_connect.py +8 -7
  32. metalstack/api/v2/filesystem_pb2.py +3 -3
  33. metalstack/api/v2/health_connect.py +6 -5
  34. metalstack/api/v2/health_pb2.py +3 -3
  35. metalstack/api/v2/image_connect.py +8 -7
  36. metalstack/api/v2/image_pb2.py +3 -3
  37. metalstack/api/v2/ip_connect.py +10 -9
  38. metalstack/api/v2/ip_pb2.py +3 -3
  39. metalstack/api/v2/machine_connect.py +10 -9
  40. metalstack/api/v2/machine_pb2.py +3 -3
  41. metalstack/api/v2/method_connect.py +7 -6
  42. metalstack/api/v2/method_pb2.py +3 -3
  43. metalstack/api/v2/network_connect.py +11 -10
  44. metalstack/api/v2/network_pb2.py +3 -3
  45. metalstack/api/v2/partition_connect.py +7 -6
  46. metalstack/api/v2/partition_pb2.py +3 -3
  47. metalstack/api/v2/predefined_rules_pb2.py +3 -3
  48. metalstack/api/v2/project_connect.py +18 -17
  49. metalstack/api/v2/project_pb2.py +3 -3
  50. metalstack/api/v2/size_connect.py +7 -6
  51. metalstack/api/v2/size_pb2.py +3 -3
  52. metalstack/api/v2/switch_pb2.py +19 -17
  53. metalstack/api/v2/tenant_connect.py +18 -17
  54. metalstack/api/v2/tenant_pb2.py +3 -3
  55. metalstack/api/v2/token_connect.py +11 -10
  56. metalstack/api/v2/token_pb2.py +3 -3
  57. metalstack/api/v2/user_connect.py +6 -5
  58. metalstack/api/v2/user_pb2.py +3 -3
  59. metalstack/api/v2/version_connect.py +6 -5
  60. metalstack/api/v2/version_pb2.py +3 -3
  61. metalstack/api/v2/vpn_pb2.py +3 -3
  62. metalstack/infra/v2/bmc_connect.py +71 -5
  63. metalstack/infra/v2/bmc_pb2.py +12 -6
  64. metalstack/infra/v2/bmc_pb2.pyi +8 -0
  65. metalstack/infra/v2/event_connect.py +6 -5
  66. metalstack/infra/v2/event_pb2.py +3 -3
  67. metalstack/infra/v2/switch_connect.py +8 -7
  68. metalstack/infra/v2/switch_pb2.py +3 -3
  69. metal_stack_api-0.0.38.dist-info/RECORD +0 -108
  70. {metal_stack_api-0.0.38.dist-info → metal_stack_api-0.0.40.dist-info}/top_level.txt +0 -0
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/filesystem.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/filesystem.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/health.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -20,10 +20,11 @@ class HealthService(Protocol):
20
20
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
21
21
 
22
22
 
23
- class HealthServiceASGIApplication(ConnectASGIApplication):
24
- def __init__(self, service: HealthService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
23
+ class HealthServiceASGIApplication(ConnectASGIApplication[HealthService]):
24
+ def __init__(self, service: HealthService | AsyncGenerator[HealthService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
25
25
  super().__init__(
26
- endpoints={
26
+ service=service,
27
+ endpoints=lambda svc: {
27
28
  "/metalstack.api.v2.HealthService/Get": Endpoint.unary(
28
29
  method=MethodInfo(
29
30
  name="Get",
@@ -32,7 +33,7 @@ class HealthServiceASGIApplication(ConnectASGIApplication):
32
33
  output=metalstack_dot_api_dot_v2_dot_health__pb2.HealthServiceGetResponse,
33
34
  idempotency_level=IdempotencyLevel.UNKNOWN,
34
35
  ),
35
- function=service.get,
36
+ function=svc.get,
36
37
  ),
37
38
  },
38
39
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/health.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/health.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/image.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -26,10 +26,11 @@ class ImageService(Protocol):
26
26
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
27
27
 
28
28
 
29
- class ImageServiceASGIApplication(ConnectASGIApplication):
30
- def __init__(self, service: ImageService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
29
+ class ImageServiceASGIApplication(ConnectASGIApplication[ImageService]):
30
+ def __init__(self, service: ImageService | AsyncGenerator[ImageService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
31
31
  super().__init__(
32
- endpoints={
32
+ service=service,
33
+ endpoints=lambda svc: {
33
34
  "/metalstack.api.v2.ImageService/Get": Endpoint.unary(
34
35
  method=MethodInfo(
35
36
  name="Get",
@@ -38,7 +39,7 @@ class ImageServiceASGIApplication(ConnectASGIApplication):
38
39
  output=metalstack_dot_api_dot_v2_dot_image__pb2.ImageServiceGetResponse,
39
40
  idempotency_level=IdempotencyLevel.UNKNOWN,
40
41
  ),
41
- function=service.get,
42
+ function=svc.get,
42
43
  ),
43
44
  "/metalstack.api.v2.ImageService/List": Endpoint.unary(
44
45
  method=MethodInfo(
@@ -48,7 +49,7 @@ class ImageServiceASGIApplication(ConnectASGIApplication):
48
49
  output=metalstack_dot_api_dot_v2_dot_image__pb2.ImageServiceListResponse,
49
50
  idempotency_level=IdempotencyLevel.UNKNOWN,
50
51
  ),
51
- function=service.list,
52
+ function=svc.list,
52
53
  ),
53
54
  "/metalstack.api.v2.ImageService/Latest": Endpoint.unary(
54
55
  method=MethodInfo(
@@ -58,7 +59,7 @@ class ImageServiceASGIApplication(ConnectASGIApplication):
58
59
  output=metalstack_dot_api_dot_v2_dot_image__pb2.ImageServiceLatestResponse,
59
60
  idempotency_level=IdempotencyLevel.UNKNOWN,
60
61
  ),
61
- function=service.latest,
62
+ function=svc.latest,
62
63
  ),
63
64
  },
64
65
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/image.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/image.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/ip.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -32,10 +32,11 @@ class IPService(Protocol):
32
32
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
33
33
 
34
34
 
35
- class IPServiceASGIApplication(ConnectASGIApplication):
36
- def __init__(self, service: IPService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
35
+ class IPServiceASGIApplication(ConnectASGIApplication[IPService]):
36
+ def __init__(self, service: IPService | AsyncGenerator[IPService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
37
37
  super().__init__(
38
- endpoints={
38
+ service=service,
39
+ endpoints=lambda svc: {
39
40
  "/metalstack.api.v2.IPService/Get": Endpoint.unary(
40
41
  method=MethodInfo(
41
42
  name="Get",
@@ -44,7 +45,7 @@ class IPServiceASGIApplication(ConnectASGIApplication):
44
45
  output=metalstack_dot_api_dot_v2_dot_ip__pb2.IPServiceGetResponse,
45
46
  idempotency_level=IdempotencyLevel.UNKNOWN,
46
47
  ),
47
- function=service.get,
48
+ function=svc.get,
48
49
  ),
49
50
  "/metalstack.api.v2.IPService/Create": Endpoint.unary(
50
51
  method=MethodInfo(
@@ -54,7 +55,7 @@ class IPServiceASGIApplication(ConnectASGIApplication):
54
55
  output=metalstack_dot_api_dot_v2_dot_ip__pb2.IPServiceCreateResponse,
55
56
  idempotency_level=IdempotencyLevel.UNKNOWN,
56
57
  ),
57
- function=service.create,
58
+ function=svc.create,
58
59
  ),
59
60
  "/metalstack.api.v2.IPService/Update": Endpoint.unary(
60
61
  method=MethodInfo(
@@ -64,7 +65,7 @@ class IPServiceASGIApplication(ConnectASGIApplication):
64
65
  output=metalstack_dot_api_dot_v2_dot_ip__pb2.IPServiceUpdateResponse,
65
66
  idempotency_level=IdempotencyLevel.UNKNOWN,
66
67
  ),
67
- function=service.update,
68
+ function=svc.update,
68
69
  ),
69
70
  "/metalstack.api.v2.IPService/List": Endpoint.unary(
70
71
  method=MethodInfo(
@@ -74,7 +75,7 @@ class IPServiceASGIApplication(ConnectASGIApplication):
74
75
  output=metalstack_dot_api_dot_v2_dot_ip__pb2.IPServiceListResponse,
75
76
  idempotency_level=IdempotencyLevel.UNKNOWN,
76
77
  ),
77
- function=service.list,
78
+ function=svc.list,
78
79
  ),
79
80
  "/metalstack.api.v2.IPService/Delete": Endpoint.unary(
80
81
  method=MethodInfo(
@@ -84,7 +85,7 @@ class IPServiceASGIApplication(ConnectASGIApplication):
84
85
  output=metalstack_dot_api_dot_v2_dot_ip__pb2.IPServiceDeleteResponse,
85
86
  idempotency_level=IdempotencyLevel.UNKNOWN,
86
87
  ),
87
- function=service.delete,
88
+ function=svc.delete,
88
89
  ),
89
90
  },
90
91
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/ip.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/ip.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/machine.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -32,10 +32,11 @@ class MachineService(Protocol):
32
32
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
33
33
 
34
34
 
35
- class MachineServiceASGIApplication(ConnectASGIApplication):
36
- def __init__(self, service: MachineService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
35
+ class MachineServiceASGIApplication(ConnectASGIApplication[MachineService]):
36
+ def __init__(self, service: MachineService | AsyncGenerator[MachineService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
37
37
  super().__init__(
38
- endpoints={
38
+ service=service,
39
+ endpoints=lambda svc: {
39
40
  "/metalstack.api.v2.MachineService/Get": Endpoint.unary(
40
41
  method=MethodInfo(
41
42
  name="Get",
@@ -44,7 +45,7 @@ class MachineServiceASGIApplication(ConnectASGIApplication):
44
45
  output=metalstack_dot_api_dot_v2_dot_machine__pb2.MachineServiceGetResponse,
45
46
  idempotency_level=IdempotencyLevel.UNKNOWN,
46
47
  ),
47
- function=service.get,
48
+ function=svc.get,
48
49
  ),
49
50
  "/metalstack.api.v2.MachineService/Create": Endpoint.unary(
50
51
  method=MethodInfo(
@@ -54,7 +55,7 @@ class MachineServiceASGIApplication(ConnectASGIApplication):
54
55
  output=metalstack_dot_api_dot_v2_dot_machine__pb2.MachineServiceCreateResponse,
55
56
  idempotency_level=IdempotencyLevel.UNKNOWN,
56
57
  ),
57
- function=service.create,
58
+ function=svc.create,
58
59
  ),
59
60
  "/metalstack.api.v2.MachineService/Update": Endpoint.unary(
60
61
  method=MethodInfo(
@@ -64,7 +65,7 @@ class MachineServiceASGIApplication(ConnectASGIApplication):
64
65
  output=metalstack_dot_api_dot_v2_dot_machine__pb2.MachineServiceUpdateResponse,
65
66
  idempotency_level=IdempotencyLevel.UNKNOWN,
66
67
  ),
67
- function=service.update,
68
+ function=svc.update,
68
69
  ),
69
70
  "/metalstack.api.v2.MachineService/List": Endpoint.unary(
70
71
  method=MethodInfo(
@@ -74,7 +75,7 @@ class MachineServiceASGIApplication(ConnectASGIApplication):
74
75
  output=metalstack_dot_api_dot_v2_dot_machine__pb2.MachineServiceListResponse,
75
76
  idempotency_level=IdempotencyLevel.UNKNOWN,
76
77
  ),
77
- function=service.list,
78
+ function=svc.list,
78
79
  ),
79
80
  "/metalstack.api.v2.MachineService/Delete": Endpoint.unary(
80
81
  method=MethodInfo(
@@ -84,7 +85,7 @@ class MachineServiceASGIApplication(ConnectASGIApplication):
84
85
  output=metalstack_dot_api_dot_v2_dot_machine__pb2.MachineServiceDeleteResponse,
85
86
  idempotency_level=IdempotencyLevel.UNKNOWN,
86
87
  ),
87
- function=service.delete,
88
+ function=svc.delete,
88
89
  ),
89
90
  },
90
91
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/machine.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/machine.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/method.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -23,10 +23,11 @@ class MethodService(Protocol):
23
23
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
24
24
 
25
25
 
26
- class MethodServiceASGIApplication(ConnectASGIApplication):
27
- def __init__(self, service: MethodService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
26
+ class MethodServiceASGIApplication(ConnectASGIApplication[MethodService]):
27
+ def __init__(self, service: MethodService | AsyncGenerator[MethodService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
28
28
  super().__init__(
29
- endpoints={
29
+ service=service,
30
+ endpoints=lambda svc: {
30
31
  "/metalstack.api.v2.MethodService/List": Endpoint.unary(
31
32
  method=MethodInfo(
32
33
  name="List",
@@ -35,7 +36,7 @@ class MethodServiceASGIApplication(ConnectASGIApplication):
35
36
  output=metalstack_dot_api_dot_v2_dot_method__pb2.MethodServiceListResponse,
36
37
  idempotency_level=IdempotencyLevel.UNKNOWN,
37
38
  ),
38
- function=service.list,
39
+ function=svc.list,
39
40
  ),
40
41
  "/metalstack.api.v2.MethodService/TokenScopedList": Endpoint.unary(
41
42
  method=MethodInfo(
@@ -45,7 +46,7 @@ class MethodServiceASGIApplication(ConnectASGIApplication):
45
46
  output=metalstack_dot_api_dot_v2_dot_method__pb2.MethodServiceTokenScopedListResponse,
46
47
  idempotency_level=IdempotencyLevel.UNKNOWN,
47
48
  ),
48
- function=service.token_scoped_list,
49
+ function=svc.token_scoped_list,
49
50
  ),
50
51
  },
51
52
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/method.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/method.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/network.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -35,10 +35,11 @@ class NetworkService(Protocol):
35
35
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
36
36
 
37
37
 
38
- class NetworkServiceASGIApplication(ConnectASGIApplication):
39
- def __init__(self, service: NetworkService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
38
+ class NetworkServiceASGIApplication(ConnectASGIApplication[NetworkService]):
39
+ def __init__(self, service: NetworkService | AsyncGenerator[NetworkService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
40
40
  super().__init__(
41
- endpoints={
41
+ service=service,
42
+ endpoints=lambda svc: {
42
43
  "/metalstack.api.v2.NetworkService/Get": Endpoint.unary(
43
44
  method=MethodInfo(
44
45
  name="Get",
@@ -47,7 +48,7 @@ class NetworkServiceASGIApplication(ConnectASGIApplication):
47
48
  output=metalstack_dot_api_dot_v2_dot_network__pb2.NetworkServiceGetResponse,
48
49
  idempotency_level=IdempotencyLevel.UNKNOWN,
49
50
  ),
50
- function=service.get,
51
+ function=svc.get,
51
52
  ),
52
53
  "/metalstack.api.v2.NetworkService/Create": Endpoint.unary(
53
54
  method=MethodInfo(
@@ -57,7 +58,7 @@ class NetworkServiceASGIApplication(ConnectASGIApplication):
57
58
  output=metalstack_dot_api_dot_v2_dot_network__pb2.NetworkServiceCreateResponse,
58
59
  idempotency_level=IdempotencyLevel.UNKNOWN,
59
60
  ),
60
- function=service.create,
61
+ function=svc.create,
61
62
  ),
62
63
  "/metalstack.api.v2.NetworkService/Update": Endpoint.unary(
63
64
  method=MethodInfo(
@@ -67,7 +68,7 @@ class NetworkServiceASGIApplication(ConnectASGIApplication):
67
68
  output=metalstack_dot_api_dot_v2_dot_network__pb2.NetworkServiceUpdateResponse,
68
69
  idempotency_level=IdempotencyLevel.UNKNOWN,
69
70
  ),
70
- function=service.update,
71
+ function=svc.update,
71
72
  ),
72
73
  "/metalstack.api.v2.NetworkService/List": Endpoint.unary(
73
74
  method=MethodInfo(
@@ -77,7 +78,7 @@ class NetworkServiceASGIApplication(ConnectASGIApplication):
77
78
  output=metalstack_dot_api_dot_v2_dot_network__pb2.NetworkServiceListResponse,
78
79
  idempotency_level=IdempotencyLevel.UNKNOWN,
79
80
  ),
80
- function=service.list,
81
+ function=svc.list,
81
82
  ),
82
83
  "/metalstack.api.v2.NetworkService/ListBaseNetworks": Endpoint.unary(
83
84
  method=MethodInfo(
@@ -87,7 +88,7 @@ class NetworkServiceASGIApplication(ConnectASGIApplication):
87
88
  output=metalstack_dot_api_dot_v2_dot_network__pb2.NetworkServiceListBaseNetworksResponse,
88
89
  idempotency_level=IdempotencyLevel.UNKNOWN,
89
90
  ),
90
- function=service.list_base_networks,
91
+ function=svc.list_base_networks,
91
92
  ),
92
93
  "/metalstack.api.v2.NetworkService/Delete": Endpoint.unary(
93
94
  method=MethodInfo(
@@ -97,7 +98,7 @@ class NetworkServiceASGIApplication(ConnectASGIApplication):
97
98
  output=metalstack_dot_api_dot_v2_dot_network__pb2.NetworkServiceDeleteResponse,
98
99
  idempotency_level=IdempotencyLevel.UNKNOWN,
99
100
  ),
100
- function=service.delete,
101
+ function=svc.delete,
101
102
  ),
102
103
  },
103
104
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/network.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/network.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by https://github.com/connectrpc/connect-python. DO NOT EDIT!
3
3
  # source: metalstack/api/v2/partition.proto
4
4
 
5
- from collections.abc import AsyncIterator, Iterable, Iterator, Mapping
5
+ from collections.abc import AsyncGenerator, AsyncIterator, Iterable, Iterator, Mapping
6
6
  from typing import Protocol
7
7
 
8
8
  from connectrpc.client import ConnectClient, ConnectClientSync
@@ -23,10 +23,11 @@ class PartitionService(Protocol):
23
23
  raise ConnectError(Code.UNIMPLEMENTED, "Not implemented")
24
24
 
25
25
 
26
- class PartitionServiceASGIApplication(ConnectASGIApplication):
27
- def __init__(self, service: PartitionService, *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
26
+ class PartitionServiceASGIApplication(ConnectASGIApplication[PartitionService]):
27
+ def __init__(self, service: PartitionService | AsyncGenerator[PartitionService], *, interceptors: Iterable[Interceptor]=(), read_max_bytes: int | None = None) -> None:
28
28
  super().__init__(
29
- endpoints={
29
+ service=service,
30
+ endpoints=lambda svc: {
30
31
  "/metalstack.api.v2.PartitionService/Get": Endpoint.unary(
31
32
  method=MethodInfo(
32
33
  name="Get",
@@ -35,7 +36,7 @@ class PartitionServiceASGIApplication(ConnectASGIApplication):
35
36
  output=metalstack_dot_api_dot_v2_dot_partition__pb2.PartitionServiceGetResponse,
36
37
  idempotency_level=IdempotencyLevel.UNKNOWN,
37
38
  ),
38
- function=service.get,
39
+ function=svc.get,
39
40
  ),
40
41
  "/metalstack.api.v2.PartitionService/List": Endpoint.unary(
41
42
  method=MethodInfo(
@@ -45,7 +46,7 @@ class PartitionServiceASGIApplication(ConnectASGIApplication):
45
46
  output=metalstack_dot_api_dot_v2_dot_partition__pb2.PartitionServiceListResponse,
46
47
  idempotency_level=IdempotencyLevel.UNKNOWN,
47
48
  ),
48
- function=service.list,
49
+ function=svc.list,
49
50
  ),
50
51
  },
51
52
  interceptors=interceptors,
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/partition.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/partition.proto'
19
19
  )
@@ -2,7 +2,7 @@
2
2
  # Generated by the protocol buffer compiler. DO NOT EDIT!
3
3
  # NO CHECKED-IN PROTOBUF GENCODE
4
4
  # source: metalstack/api/v2/predefined_rules.proto
5
- # Protobuf Python Version: 6.32.1
5
+ # Protobuf Python Version: 6.33.4
6
6
  """Generated protocol buffer code."""
7
7
  from google.protobuf import descriptor as _descriptor
8
8
  from google.protobuf import descriptor_pool as _descriptor_pool
@@ -12,8 +12,8 @@ from google.protobuf.internal import builder as _builder
12
12
  _runtime_version.ValidateProtobufRuntimeVersion(
13
13
  _runtime_version.Domain.PUBLIC,
14
14
  6,
15
- 32,
16
- 1,
15
+ 33,
16
+ 4,
17
17
  '',
18
18
  'metalstack/api/v2/predefined_rules.proto'
19
19
  )