modal 0.67.40__py3-none-any.whl → 0.67.41__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.
modal/client.pyi CHANGED
@@ -26,7 +26,7 @@ class _Client:
26
26
  _stub: typing.Optional[modal_proto.api_grpc.ModalClientStub]
27
27
 
28
28
  def __init__(
29
- self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.67.40"
29
+ self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.67.41"
30
30
  ): ...
31
31
  def is_closed(self) -> bool: ...
32
32
  @property
@@ -81,7 +81,7 @@ class Client:
81
81
  _stub: typing.Optional[modal_proto.api_grpc.ModalClientStub]
82
82
 
83
83
  def __init__(
84
- self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.67.40"
84
+ self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.67.41"
85
85
  ): ...
86
86
  def is_closed(self) -> bool: ...
87
87
  @property
modal/functions.pyi CHANGED
@@ -455,11 +455,11 @@ class Function(typing.Generic[P, ReturnType, OriginalReturnType], modal.object.O
455
455
 
456
456
  _call_generator_nowait: ___call_generator_nowait_spec
457
457
 
458
- class __remote_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER]):
458
+ class __remote_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
459
459
  def __call__(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER: ...
460
460
  async def aio(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER: ...
461
461
 
462
- remote: __remote_spec[P, ReturnType]
462
+ remote: __remote_spec[ReturnType, P]
463
463
 
464
464
  class __remote_gen_spec(typing_extensions.Protocol):
465
465
  def __call__(self, *args, **kwargs) -> typing.Generator[typing.Any, None, None]: ...
@@ -471,17 +471,17 @@ class Function(typing.Generic[P, ReturnType, OriginalReturnType], modal.object.O
471
471
  def _get_obj(self) -> typing.Optional[modal.cls.Obj]: ...
472
472
  def local(self, *args: P.args, **kwargs: P.kwargs) -> OriginalReturnType: ...
473
473
 
474
- class ___experimental_spawn_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER]):
474
+ class ___experimental_spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
475
475
  def __call__(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
476
476
  async def aio(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
477
477
 
478
- _experimental_spawn: ___experimental_spawn_spec[P, ReturnType]
478
+ _experimental_spawn: ___experimental_spawn_spec[ReturnType, P]
479
479
 
480
- class __spawn_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER]):
480
+ class __spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
481
481
  def __call__(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
482
482
  async def aio(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
483
483
 
484
- spawn: __spawn_spec[P, ReturnType]
484
+ spawn: __spawn_spec[ReturnType, P]
485
485
 
486
486
  def get_raw_f(self) -> typing.Callable[..., typing.Any]: ...
487
487
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: modal
3
- Version: 0.67.40
3
+ Version: 0.67.41
4
4
  Summary: Python client library for Modal
5
5
  Author: Modal Labs
6
6
  Author-email: support@modal.com
@@ -19,7 +19,7 @@ modal/app.py,sha256=EJ7FUN6rWnSwLJoYJh8nmKg_t-8hdN8_rt0OrkP7JvQ,46084
19
19
  modal/app.pyi,sha256=BE5SlR5tRECuc6-e2lUuOknDdov3zxgZ4N0AsLb5ZVQ,25270
20
20
  modal/call_graph.py,sha256=1g2DGcMIJvRy-xKicuf63IVE98gJSnQsr8R_NVMptNc,2581
21
21
  modal/client.py,sha256=cmylZhU35txmrx4nltNYuuqXRgeoMtm0ow1J9wJkEYQ,16400
22
- modal/client.pyi,sha256=4S85O-xfVK3PbxZndQ8LworEUAZWNQrse4vbwA9UU3E,7354
22
+ modal/client.pyi,sha256=Ib2roAy5eGLisWtjCXqmKHgnNo1ArcJiKYb5N9TW8tQ,7354
23
23
  modal/cloud_bucket_mount.py,sha256=G7T7jWLD0QkmrfKR75mSTwdUZ2xNfj7pkVqb4ipmxmI,5735
24
24
  modal/cloud_bucket_mount.pyi,sha256=CEi7vrH3kDUF4LAy4qP6tfImy2UJuFRcRbsgRNM1wo8,1403
25
25
  modal/cls.py,sha256=OJqzj_V-n1g48BY_4Jg_BOTQdftEEl4kTWN0X4FOOdg,27378
@@ -34,7 +34,7 @@ modal/environments.pyi,sha256=XalNpiPkAtHWAvOU2Cotq0ozmtl-Jv0FDsR8h9mr27Q,3521
34
34
  modal/exception.py,sha256=EBkdWVved2XEPsXaoPRu56xfxFFHL9iuqvUsdj42WDA,6392
35
35
  modal/experimental.py,sha256=jFuNbwrNHos47viMB9q-cHJSvf2RDxDdoEcss9plaZE,2302
36
36
  modal/functions.py,sha256=3GjjFbf40XciWAa4rTmh0erkZjPzRjKHqWxUu91mHOU,66685
37
- modal/functions.pyi,sha256=IyuM9TV79JfrtfTaJ4yq3EcWp3yHuxLavpxTOwSWEDw,24988
37
+ modal/functions.pyi,sha256=4k5CaJ9iTuEyHQ2rC5OysNHBLv1CZrD7zBMU1zXIU4w,24988
38
38
  modal/gpu.py,sha256=r4rL6uH3UJIQthzYvfWauXNyh01WqCPtKZCmmSX1fd4,6881
39
39
  modal/image.py,sha256=cQ6WP1xHXZT_nY8z3aEFiGwKzrTV0yxi3Ab8JzF91eo,79653
40
40
  modal/image.pyi,sha256=PIKH6JBA4L5TfdJrQu3pm2ykyIITmiP920TpP8cdyQA,24585
@@ -142,13 +142,13 @@ modal_global_objects/mounts/__init__.py,sha256=MIEP8jhXUeGq_eCjYFcqN5b1bxBM4fdk0
142
142
  modal_global_objects/mounts/modal_client_package.py,sha256=W0E_yShsRojPzWm6LtIQqNVolapdnrZkm2hVEQuZK_4,767
143
143
  modal_global_objects/mounts/python_standalone.py,sha256=SL_riIxpd8mP4i4CLDCWiFFNj0Ltknm9c_UIGfX5d60,1836
144
144
  modal_proto/__init__.py,sha256=MIEP8jhXUeGq_eCjYFcqN5b1bxBM4fdk0VESpjWR0fc,28
145
- modal_proto/api.proto,sha256=0AWqw9MDQvRrQTZI2xa8fVRcbs2lJG1DDt42ijBaJeY,78122
146
- modal_proto/api_grpc.py,sha256=HvNN-zBJUs6z-a1T9Jn2ECs-Fs7RnkJ4FVzPTH6xU98,100519
147
- modal_proto/api_pb2.py,sha256=hTsHAAKqmUxctck2FbpmOX4QTeF5pkNR_4BDYkrCxjk,284470
148
- modal_proto/api_pb2.pyi,sha256=n9SMpTlIG3qhNI6XBc3gez5OeSzuaRfs4jkfu8WMIRw,380221
149
- modal_proto/api_pb2_grpc.py,sha256=VFMzQ9MYmPg1XbTnmdjyw3MKhcPcqpBXtsQvtTn1uDI,217438
150
- modal_proto/api_pb2_grpc.pyi,sha256=1o_3hja-2Y0iAlZDxnIXgahZQuaM6ruWLuc_2YoFuls,50691
151
- modal_proto/modal_api_grpc.py,sha256=qUVht8AH8avTG2fm7Gw4pLwbgQTfqVgF5s_17HcrGKk,13438
145
+ modal_proto/api.proto,sha256=e1htlTwZbWpNA3khziIYetwU0Mf6dBuyFGDiv_7jbl4,78446
146
+ modal_proto/api_grpc.py,sha256=DveC4ejFYEhCLiWbQShnmY31_FWGYU675Bmr7nHhsgs,101342
147
+ modal_proto/api_pb2.py,sha256=WuaJmwcoq39U09SZu73D-rowGWxKw57GHvTgDhkQlEI,286035
148
+ modal_proto/api_pb2.pyi,sha256=W-KCpNsYftytboeYOVR7qwekOwN4htwyHWD0OMOfmA8,381838
149
+ modal_proto/api_pb2_grpc.py,sha256=2PEP6JPOoTw2rDC5qYjLNuumP68ZwAouRhCoayisAhY,219162
150
+ modal_proto/api_pb2_grpc.pyi,sha256=uWtCxVEd0cFpOZ1oOGfZNO7Dv45OP4kp09jMnNyx9D4,51098
151
+ modal_proto/modal_api_grpc.py,sha256=-8mLby_om5MYo6yu1zA_hqhz0yLsQW7k2YWBVZW1iVs,13546
152
152
  modal_proto/modal_options_grpc.py,sha256=qJ1cuwA54oRqrdTyPTbvfhFZYd9HhJKK5UCwt523r3Y,120
153
153
  modal_proto/options.proto,sha256=a-siq4swVbZPfaFRXAipRZzGP2bq8OsdUvjlyzAeodQ,488
154
154
  modal_proto/options_grpc.py,sha256=M18X3d-8F_cNYSVM3I25dUTO5rZ0rd-vCCfynfh13Nc,125
@@ -159,10 +159,10 @@ modal_proto/options_pb2_grpc.pyi,sha256=CImmhxHsYnF09iENPoe8S4J-n93jtgUYD2JPAc0y
159
159
  modal_proto/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
160
160
  modal_version/__init__.py,sha256=3IY-AWLH55r35_mQXIaut0jrJvoPuf1NZJBQQfSbPuo,470
161
161
  modal_version/__main__.py,sha256=2FO0yYQQwDTh6udt1h-cBnGd1c4ZyHnHSI4BksxzVac,105
162
- modal_version/_version_generated.py,sha256=5gLMLY-cYu0FT5xTjYMlRGB5AwCo0WwwtxIwDntd8t0,149
163
- modal-0.67.40.dist-info/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
164
- modal-0.67.40.dist-info/METADATA,sha256=uIBq5XeGQA9EgjAJY_75cg1J-jpSZb34icpK7S96g_8,2329
165
- modal-0.67.40.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
166
- modal-0.67.40.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
167
- modal-0.67.40.dist-info/top_level.txt,sha256=1nvYbOSIKcmU50fNrpnQnrrOpj269ei3LzgB6j9xGqg,64
168
- modal-0.67.40.dist-info/RECORD,,
162
+ modal_version/_version_generated.py,sha256=zLxUz4y1G_2ypx20CwyXB6ow78uz1EyykhkfvWlzC9Y,149
163
+ modal-0.67.41.dist-info/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
164
+ modal-0.67.41.dist-info/METADATA,sha256=Nza7dGL56OkjAEN3hE333GijLaEH4DSHo7t_3KmUSy8,2329
165
+ modal-0.67.41.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
166
+ modal-0.67.41.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
167
+ modal-0.67.41.dist-info/top_level.txt,sha256=1nvYbOSIKcmU50fNrpnQnrrOpj269ei3LzgB6j9xGqg,64
168
+ modal-0.67.41.dist-info/RECORD,,
modal_proto/api.proto CHANGED
@@ -1211,6 +1211,17 @@ message Function {
1211
1211
  bool _experimental_custom_scaling = 76;
1212
1212
  }
1213
1213
 
1214
+ message FunctionAsyncInvokeRequest {
1215
+ string function_id = 1;
1216
+ string parent_input_id = 2;
1217
+ FunctionInput input = 3;
1218
+ }
1219
+
1220
+ message FunctionAsyncInvokeResponse {
1221
+ bool retry_with_blob_upload = 1;
1222
+ string function_call_id = 2;
1223
+ }
1224
+
1214
1225
  message FunctionBindParamsRequest {
1215
1226
  string function_id = 1;
1216
1227
  bytes serialized_params = 2;
@@ -2705,6 +2716,7 @@ service ModalClient {
2705
2716
  rpc EnvironmentUpdate(EnvironmentUpdateRequest) returns (EnvironmentListItem);
2706
2717
 
2707
2718
  // Functions
2719
+ rpc FunctionAsyncInvoke(FunctionAsyncInvokeRequest) returns (FunctionAsyncInvokeResponse);
2708
2720
  rpc FunctionBindParams(FunctionBindParamsRequest) returns (FunctionBindParamsResponse);
2709
2721
  rpc FunctionCallCancel(FunctionCallCancelRequest) returns (google.protobuf.Empty);
2710
2722
  rpc FunctionCallGetDataIn(FunctionCallGetDataRequest) returns (stream DataChunk);
modal_proto/api_grpc.py CHANGED
@@ -217,6 +217,10 @@ class ModalClientBase(abc.ABC):
217
217
  async def EnvironmentUpdate(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.EnvironmentUpdateRequest, modal_proto.api_pb2.EnvironmentListItem]') -> None:
218
218
  pass
219
219
 
220
+ @abc.abstractmethod
221
+ async def FunctionAsyncInvoke(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.FunctionAsyncInvokeRequest, modal_proto.api_pb2.FunctionAsyncInvokeResponse]') -> None:
222
+ pass
223
+
220
224
  @abc.abstractmethod
221
225
  async def FunctionBindParams(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.FunctionBindParamsRequest, modal_proto.api_pb2.FunctionBindParamsResponse]') -> None:
222
226
  pass
@@ -843,6 +847,12 @@ class ModalClientBase(abc.ABC):
843
847
  modal_proto.api_pb2.EnvironmentUpdateRequest,
844
848
  modal_proto.api_pb2.EnvironmentListItem,
845
849
  ),
850
+ '/modal.client.ModalClient/FunctionAsyncInvoke': grpclib.const.Handler(
851
+ self.FunctionAsyncInvoke,
852
+ grpclib.const.Cardinality.UNARY_UNARY,
853
+ modal_proto.api_pb2.FunctionAsyncInvokeRequest,
854
+ modal_proto.api_pb2.FunctionAsyncInvokeResponse,
855
+ ),
846
856
  '/modal.client.ModalClient/FunctionBindParams': grpclib.const.Handler(
847
857
  self.FunctionBindParams,
848
858
  grpclib.const.Cardinality.UNARY_UNARY,
@@ -1635,6 +1645,12 @@ class ModalClientStub:
1635
1645
  modal_proto.api_pb2.EnvironmentUpdateRequest,
1636
1646
  modal_proto.api_pb2.EnvironmentListItem,
1637
1647
  )
1648
+ self.FunctionAsyncInvoke = grpclib.client.UnaryUnaryMethod(
1649
+ channel,
1650
+ '/modal.client.ModalClient/FunctionAsyncInvoke',
1651
+ modal_proto.api_pb2.FunctionAsyncInvokeRequest,
1652
+ modal_proto.api_pb2.FunctionAsyncInvokeResponse,
1653
+ )
1638
1654
  self.FunctionBindParams = grpclib.client.UnaryUnaryMethod(
1639
1655
  channel,
1640
1656
  '/modal.client.ModalClient/FunctionBindParams',