modal 1.1.1.dev17__py3-none-any.whl → 1.1.1.dev19__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.

Potentially problematic release.


This version of modal might be problematic. Click here for more details.

modal/client.pyi CHANGED
@@ -33,7 +33,7 @@ class _Client:
33
33
  server_url: str,
34
34
  client_type: int,
35
35
  credentials: typing.Optional[tuple[str, str]],
36
- version: str = "1.1.1.dev17",
36
+ version: str = "1.1.1.dev19",
37
37
  ):
38
38
  """mdmd:hidden
39
39
  The Modal client object is not intended to be instantiated directly by users.
@@ -164,7 +164,7 @@ class Client:
164
164
  server_url: str,
165
165
  client_type: int,
166
166
  credentials: typing.Optional[tuple[str, str]],
167
- version: str = "1.1.1.dev17",
167
+ version: str = "1.1.1.dev19",
168
168
  ):
169
169
  """mdmd:hidden
170
170
  The Modal client object is not intended to be instantiated directly by users.
modal/functions.pyi CHANGED
@@ -428,7 +428,7 @@ class Function(
428
428
 
429
429
  _call_generator: ___call_generator_spec[typing_extensions.Self]
430
430
 
431
- class __remote_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER, SUPERSELF]):
431
+ class __remote_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER, SUPERSELF]):
432
432
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER:
433
433
  """Calls the function remotely, executing it with the given arguments and returning the execution's result."""
434
434
  ...
@@ -437,7 +437,7 @@ class Function(
437
437
  """Calls the function remotely, executing it with the given arguments and returning the execution's result."""
438
438
  ...
439
439
 
440
- remote: __remote_spec[modal._functions.P, modal._functions.ReturnType, typing_extensions.Self]
440
+ remote: __remote_spec[modal._functions.ReturnType, modal._functions.P, typing_extensions.Self]
441
441
 
442
442
  class __remote_gen_spec(typing_extensions.Protocol[SUPERSELF]):
443
443
  def __call__(self, /, *args, **kwargs) -> typing.Generator[typing.Any, None, None]:
@@ -464,7 +464,7 @@ class Function(
464
464
  """
465
465
  ...
466
466
 
467
- class ___experimental_spawn_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER, SUPERSELF]):
467
+ class ___experimental_spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER, SUPERSELF]):
468
468
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]:
469
469
  """[Experimental] Calls the function with the given arguments, without waiting for the results.
470
470
 
@@ -488,7 +488,7 @@ class Function(
488
488
  ...
489
489
 
490
490
  _experimental_spawn: ___experimental_spawn_spec[
491
- modal._functions.P, modal._functions.ReturnType, typing_extensions.Self
491
+ modal._functions.ReturnType, modal._functions.P, typing_extensions.Self
492
492
  ]
493
493
 
494
494
  class ___spawn_map_inner_spec(typing_extensions.Protocol[P_INNER, SUPERSELF]):
@@ -497,7 +497,7 @@ class Function(
497
497
 
498
498
  _spawn_map_inner: ___spawn_map_inner_spec[modal._functions.P, typing_extensions.Self]
499
499
 
500
- class __spawn_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER, SUPERSELF]):
500
+ class __spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER, SUPERSELF]):
501
501
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]:
502
502
  """Calls the function with the given arguments, without waiting for the results.
503
503
 
@@ -518,7 +518,7 @@ class Function(
518
518
  """
519
519
  ...
520
520
 
521
- spawn: __spawn_spec[modal._functions.P, modal._functions.ReturnType, typing_extensions.Self]
521
+ spawn: __spawn_spec[modal._functions.ReturnType, modal._functions.P, typing_extensions.Self]
522
522
 
523
523
  def get_raw_f(self) -> collections.abc.Callable[..., typing.Any]:
524
524
  """Return the inner Python object wrapped by this Modal Function."""
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: modal
3
- Version: 1.1.1.dev17
3
+ Version: 1.1.1.dev19
4
4
  Summary: Python client library for Modal
5
5
  Author-email: Modal Labs <support@modal.com>
6
6
  License: Apache-2.0
@@ -22,7 +22,7 @@ modal/app.py,sha256=BBR2NmGzZbFGfhKAmtzllD0o4TbVDBbOEs0O2ysSdQo,48277
22
22
  modal/app.pyi,sha256=h6JtBA6a7wobdZAuS3QuXrWCUZqfyKPuGV3XdjCqT3k,43753
23
23
  modal/call_graph.py,sha256=1g2DGcMIJvRy-xKicuf63IVE98gJSnQsr8R_NVMptNc,2581
24
24
  modal/client.py,sha256=kyAIVB3Ay-XKJizQ_1ufUFB__EagV0MLmHJpyYyJ7J0,18636
25
- modal/client.pyi,sha256=XD43Q4KM3hWylx3pTjw1U7DLKLaWgGxQAmfCh8mPm90,15831
25
+ modal/client.pyi,sha256=khJZygT5v8RIuvCsC46HCA-hxKfaPa9xWaiRAeXSXwE,15831
26
26
  modal/cloud_bucket_mount.py,sha256=YOe9nnvSr4ZbeCn587d7_VhE9IioZYRvF9VYQTQux08,5914
27
27
  modal/cloud_bucket_mount.pyi,sha256=-qSfYAQvIoO_l2wsCCGTG5ZUwQieNKXdAO00yP1-LYU,7394
28
28
  modal/cls.py,sha256=7A0xGnugQzm8dOfnKMjLjtqekRlRtQ0jPFRYgq6xdUM,40018
@@ -39,7 +39,7 @@ modal/file_io.py,sha256=BVqAJ0sgPUfN8QsYztWiGB4j56he60TncM02KsylnCw,21449
39
39
  modal/file_io.pyi,sha256=cPT_hsplE5iLCXhYOLn1Sp9eDdk7DxdFmicQHanJZyg,15918
40
40
  modal/file_pattern_matcher.py,sha256=urAue8es8jxqX94k9EYoZxxhtfgOlsEES8lbFHOorzc,7734
41
41
  modal/functions.py,sha256=kcNHvqeGBxPI7Cgd57NIBBghkfbeFJzXO44WW0jSmao,325
42
- modal/functions.pyi,sha256=sht8252nY3f7y20vURdjz4R-NU0_EvHjHVl97PQ1t_4,34823
42
+ modal/functions.pyi,sha256=0P4f8ew79lf0lWXObYmNFxKoUPbWmoT0CD5IqGNKFhE,34823
43
43
  modal/gpu.py,sha256=Fe5ORvVPDIstSq1xjmM6OoNgLYFWvogP9r5BgmD3hYg,6769
44
44
  modal/image.py,sha256=zwaQixosWShXR--O8uimZZFyiLj4Xkry8s4CVwlbgz8,102697
45
45
  modal/image.pyi,sha256=s_AQaFoWmjLzffJGmiedFf9K1qQkedVIlsC6vRtlKS8,68161
@@ -151,7 +151,7 @@ modal/requirements/2025.06.txt,sha256=KxDaVTOwatHvboDo4lorlgJ7-n-MfAwbPwxJ0zcJqr
151
151
  modal/requirements/PREVIEW.txt,sha256=KxDaVTOwatHvboDo4lorlgJ7-n-MfAwbPwxJ0zcJqrs,312
152
152
  modal/requirements/README.md,sha256=9tK76KP0Uph7O0M5oUgsSwEZDj5y-dcUPsnpR0Sc-Ik,854
153
153
  modal/requirements/base-images.json,sha256=JYSDAgHTl-WrV_TZW5icY-IJEnbe2eQ4CZ_KN6EOZKU,1304
154
- modal-1.1.1.dev17.dist-info/licenses/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
154
+ modal-1.1.1.dev19.dist-info/licenses/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
155
155
  modal_docs/__init__.py,sha256=svYKtV8HDwDCN86zbdWqyq5T8sMdGDj0PVlzc2tIxDM,28
156
156
  modal_docs/gen_cli_docs.py,sha256=c1yfBS_x--gL5bs0N4ihMwqwX8l3IBWSkBAKNNIi6bQ,3801
157
157
  modal_docs/gen_reference_docs.py,sha256=d_CQUGQ0rfw28u75I2mov9AlS773z9rG40-yq5o7g2U,6359
@@ -159,13 +159,13 @@ modal_docs/mdmd/__init__.py,sha256=svYKtV8HDwDCN86zbdWqyq5T8sMdGDj0PVlzc2tIxDM,2
159
159
  modal_docs/mdmd/mdmd.py,sha256=eW5MzrEl7mSclDo4Uv64sQ1-4IyLggldbgUJdBVLDdI,6449
160
160
  modal_docs/mdmd/signatures.py,sha256=XJaZrK7Mdepk5fdX51A8uENiLFNil85Ud0d4MH8H5f0,3218
161
161
  modal_proto/__init__.py,sha256=MIEP8jhXUeGq_eCjYFcqN5b1bxBM4fdk0VESpjWR0fc,28
162
- modal_proto/api.proto,sha256=WY3YnVkAZ8ECqxoFLMDCdbuE9GkT5ZvD210MXrsmf1A,102211
163
- modal_proto/api_grpc.py,sha256=AL8Z1zlvrsqrxXYEv_mKroJArPV7_8eQ2bMvvswDlTQ,123880
164
- modal_proto/api_pb2.py,sha256=Jm47YCDrgyECTveReHWh7Iy4x7y16XV2uK-vIjk1j0s,358170
165
- modal_proto/api_pb2.pyi,sha256=Fpq_1Wq4n2tN0tG4HYX4F8p8NguFyXUFCFBfSe0_9j8,492016
166
- modal_proto/api_pb2_grpc.py,sha256=QmhsoHLD9BBXVl3ZpIb-0_sZzpQ1Q9OLBU7ONHHojG4,267607
167
- modal_proto/api_pb2_grpc.pyi,sha256=Wy6NAO-o06jbQHxvZiMAi08QQT8VHUJcSAmlRRL0p1M,62762
168
- modal_proto/modal_api_grpc.py,sha256=A622btdK6V3CFaZfXK63ocCUlulKYJsgM-rcEPEFv24,18703
162
+ modal_proto/api.proto,sha256=rpL3kteIlLwOqc_SJRV8I5Wf6PN-53gDIwbTqqccwyU,102706
163
+ modal_proto/api_grpc.py,sha256=WpGSvMcnGElrDaSQWmVV1XsyLNoJQ7DMbOTX_1mh554,124648
164
+ modal_proto/api_pb2.py,sha256=aGfM5udyJQzQWQfAvBKuCFO9zsseBHs1SqGaD09CXYM,360228
165
+ modal_proto/api_pb2.pyi,sha256=7u2jVaZAf1vuEK0Asf-5ZI4CXK8Fc2kNsT3cbdGDSVg,494777
166
+ modal_proto/api_pb2_grpc.py,sha256=VODlpmFdVjW7Sdo1FENf4vxktCmlmtijz5NryNIsQsc,269266
167
+ modal_proto/api_pb2_grpc.pyi,sha256=QIQgbnAmRvRQTZS-euu_KsPKRHD2z3XRlHFHnOY2mtw,63139
168
+ modal_proto/modal_api_grpc.py,sha256=0VKviuGtr-LV5-EMCkSSkmF9JivXkmWFZaCyFpMzSl8,18813
169
169
  modal_proto/modal_options_grpc.py,sha256=qJ1cuwA54oRqrdTyPTbvfhFZYd9HhJKK5UCwt523r3Y,120
170
170
  modal_proto/options.proto,sha256=zp9h5r61ivsp0XwEWwNBsVqNTbRA1VSY_UtN7sEcHtE,549
171
171
  modal_proto/options_grpc.py,sha256=M18X3d-8F_cNYSVM3I25dUTO5rZ0rd-vCCfynfh13Nc,125
@@ -174,10 +174,10 @@ modal_proto/options_pb2.pyi,sha256=l7DBrbLO7q3Ir-XDkWsajm0d0TQqqrfuX54i4BMpdQg,1
174
174
  modal_proto/options_pb2_grpc.py,sha256=1oboBPFxaTEXt9Aw7EAj8gXHDCNMhZD2VXqocC9l_gk,159
175
175
  modal_proto/options_pb2_grpc.pyi,sha256=CImmhxHsYnF09iENPoe8S4J-n93jtgUYD2JPAc0yJSI,247
176
176
  modal_proto/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
177
- modal_version/__init__.py,sha256=BnFFVMQedwR4f3YgD3Ojg8YWDj5eY1QiPuRcnal9v1o,121
177
+ modal_version/__init__.py,sha256=lMyj-P717zQLtAWZquWfzFS9O1uW0ykhgZONyl7EvWw,121
178
178
  modal_version/__main__.py,sha256=2FO0yYQQwDTh6udt1h-cBnGd1c4ZyHnHSI4BksxzVac,105
179
- modal-1.1.1.dev17.dist-info/METADATA,sha256=Bn2WbF9FHlFlz0uTYFU9Mf2SWRvLi9_Az-9qiscoW7k,2462
180
- modal-1.1.1.dev17.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
181
- modal-1.1.1.dev17.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
182
- modal-1.1.1.dev17.dist-info/top_level.txt,sha256=4BWzoKYREKUZ5iyPzZpjqx4G8uB5TWxXPDwibLcVa7k,43
183
- modal-1.1.1.dev17.dist-info/RECORD,,
179
+ modal-1.1.1.dev19.dist-info/METADATA,sha256=0-BIyLBj27EzNhyjmktgeuE959BgBE7YcGpWz37wkkM,2462
180
+ modal-1.1.1.dev19.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
181
+ modal-1.1.1.dev19.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
182
+ modal-1.1.1.dev19.dist-info/top_level.txt,sha256=4BWzoKYREKUZ5iyPzZpjqx4G8uB5TWxXPDwibLcVa7k,43
183
+ modal-1.1.1.dev19.dist-info/RECORD,,
modal_proto/api.proto CHANGED
@@ -240,6 +240,13 @@ enum SystemErrorCode {
240
240
  SYSTEM_ERROR_CODE_NOSPC = 28; // ENOSPC: No space left on device
241
241
  }
242
242
 
243
+ enum TaskSnapshotBehavior {
244
+ TASK_SNAPSHOT_BEHAVIOR_UNSPECIFIED = 0;
245
+ TASK_SNAPSHOT_BEHAVIOR_SNAPSHOT = 1;
246
+ TASK_SNAPSHOT_BEHAVIOR_RESTORE = 2;
247
+ TASK_SNAPSHOT_BEHAVIOR_NONE = 3;
248
+ }
249
+
243
250
  enum TaskState {
244
251
  TASK_STATE_UNSPECIFIED = 0;
245
252
  TASK_STATE_CREATED = 6;
@@ -2098,6 +2105,16 @@ message MapAwaitResponse {
2098
2105
  string last_entry_id = 2;
2099
2106
  }
2100
2107
 
2108
+ message MapCheckInputsRequest {
2109
+ string last_entry_id = 1;
2110
+ float timeout = 2;
2111
+ repeated string attempt_tokens = 3;
2112
+ }
2113
+
2114
+ message MapCheckInputsResponse {
2115
+ repeated bool lost = 1;
2116
+ }
2117
+
2101
2118
  message MapStartOrContinueItem {
2102
2119
  FunctionPutInputsItem input = 1;
2103
2120
  optional string attempt_token = 2; // None if this is a fresh input, otherwise it is the attempt token for a retry.
@@ -2961,6 +2978,7 @@ message TaskInfo {
2961
2978
  double enqueued_at = 5;
2962
2979
  string gpu_type = 6;
2963
2980
  string sandbox_id = 7;
2981
+ TaskSnapshotBehavior snapshot_behavior = 8;
2964
2982
  }
2965
2983
 
2966
2984
  message TaskListRequest {
@@ -3464,6 +3482,7 @@ service ModalClient {
3464
3482
 
3465
3483
  // Input Plane Map
3466
3484
  rpc MapAwait(MapAwaitRequest) returns (MapAwaitResponse);
3485
+ rpc MapCheckInputs(MapCheckInputsRequest) returns (MapCheckInputsResponse);
3467
3486
  rpc MapStartOrContinue(MapStartOrContinueRequest) returns (MapStartOrContinueResponse);
3468
3487
 
3469
3488
  // Mounts
modal_proto/api_grpc.py CHANGED
@@ -366,6 +366,10 @@ class ModalClientBase(abc.ABC):
366
366
  async def MapAwait(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.MapAwaitRequest, modal_proto.api_pb2.MapAwaitResponse]') -> None:
367
367
  pass
368
368
 
369
+ @abc.abstractmethod
370
+ async def MapCheckInputs(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.MapCheckInputsRequest, modal_proto.api_pb2.MapCheckInputsResponse]') -> None:
371
+ pass
372
+
369
373
  @abc.abstractmethod
370
374
  async def MapStartOrContinue(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.MapStartOrContinueRequest, modal_proto.api_pb2.MapStartOrContinueResponse]') -> None:
371
375
  pass
@@ -1186,6 +1190,12 @@ class ModalClientBase(abc.ABC):
1186
1190
  modal_proto.api_pb2.MapAwaitRequest,
1187
1191
  modal_proto.api_pb2.MapAwaitResponse,
1188
1192
  ),
1193
+ '/modal.client.ModalClient/MapCheckInputs': grpclib.const.Handler(
1194
+ self.MapCheckInputs,
1195
+ grpclib.const.Cardinality.UNARY_UNARY,
1196
+ modal_proto.api_pb2.MapCheckInputsRequest,
1197
+ modal_proto.api_pb2.MapCheckInputsResponse,
1198
+ ),
1189
1199
  '/modal.client.ModalClient/MapStartOrContinue': grpclib.const.Handler(
1190
1200
  self.MapStartOrContinue,
1191
1201
  grpclib.const.Cardinality.UNARY_UNARY,
@@ -2158,6 +2168,12 @@ class ModalClientStub:
2158
2168
  modal_proto.api_pb2.MapAwaitRequest,
2159
2169
  modal_proto.api_pb2.MapAwaitResponse,
2160
2170
  )
2171
+ self.MapCheckInputs = grpclib.client.UnaryUnaryMethod(
2172
+ channel,
2173
+ '/modal.client.ModalClient/MapCheckInputs',
2174
+ modal_proto.api_pb2.MapCheckInputsRequest,
2175
+ modal_proto.api_pb2.MapCheckInputsResponse,
2176
+ )
2161
2177
  self.MapStartOrContinue = grpclib.client.UnaryUnaryMethod(
2162
2178
  channel,
2163
2179
  '/modal.client.ModalClient/MapStartOrContinue',