modal 1.5.3.dev2__py3-none-any.whl → 1.5.3.dev3__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/_functions.py CHANGED
@@ -627,6 +627,7 @@ class _Function(typing.Generic[P, ReturnType, OriginalReturnType], _Object, type
627
627
  _metadata: api_pb2.FunctionHandleMetadata | None = None
628
628
  _options: _FunctionOptions
629
629
  _base_function: "_Function | None" = None
630
+ _app_id: str | None = None
630
631
 
631
632
  @staticmethod
632
633
  def from_local(
@@ -1403,6 +1404,7 @@ class _Function(typing.Generic[P, ReturnType, OriginalReturnType], _Object, type
1403
1404
  metadata.max_object_size_bytes if metadata.HasField("max_object_size_bytes") else MAX_OBJECT_SIZE_BYTES
1404
1405
  )
1405
1406
  self._experimental_flash_urls = metadata._experimental_flash_urls
1407
+ self._app_id = metadata.app_id or None
1406
1408
 
1407
1409
  # Invalidate the Function variant cache when we load new metadata, since the base Function handle
1408
1410
  # is now in sync with the server but any previously-cached variants may be stale.
@@ -1412,6 +1414,7 @@ class _Function(typing.Generic[P, ReturnType, OriginalReturnType], _Object, type
1412
1414
  # Overridden concrete implementation of base class method
1413
1415
  assert self._function_name, f"Function name must be set before metadata can be retrieved for {self}"
1414
1416
  return api_pb2.FunctionHandleMetadata(
1417
+ app_id=self._app_id or "",
1415
1418
  function_name=self._function_name,
1416
1419
  function_type=get_function_type(self._is_generator),
1417
1420
  web_url=self._web_url or "",
@@ -1673,6 +1676,8 @@ class _Function(typing.Generic[P, ReturnType, OriginalReturnType], _Object, type
1673
1676
  )
1674
1677
  fc: _FunctionCall[ReturnType] = _FunctionCall._new_hydrated(function_call_id, self.client, None)
1675
1678
  fc._num_inputs = num_inputs # set the cached value of num_inputs
1679
+ fc._app_id = self._app_id
1680
+ fc._function_id = self.object_id
1676
1681
  return fc
1677
1682
 
1678
1683
  async def _call_function(self, args, kwargs) -> ReturnType:
@@ -1884,6 +1889,8 @@ class _Function(typing.Generic[P, ReturnType, OriginalReturnType], _Object, type
1884
1889
  invocation.function_call_id, invocation.client, None
1885
1890
  )
1886
1891
  fc._is_generator = self._is_generator if self._is_generator else False
1892
+ fc._app_id = self._app_id
1893
+ fc._function_id = self.object_id
1887
1894
  return fc
1888
1895
 
1889
1896
  @synchronizer.no_input_translation
@@ -1920,6 +1927,8 @@ class _Function(typing.Generic[P, ReturnType, OriginalReturnType], _Object, type
1920
1927
  fc: _FunctionCall[ReturnType] = _FunctionCall._new_hydrated(
1921
1928
  invocation.function_call_id, invocation.client, None
1922
1929
  )
1930
+ fc._app_id = self._app_id
1931
+ fc._function_id = self.object_id
1923
1932
  return fc
1924
1933
 
1925
1934
  def get_raw_f(self) -> Callable[..., Any]:
@@ -1979,10 +1988,18 @@ class _FunctionCall(typing.Generic[ReturnType], _Object, type_prefix="fc"):
1979
1988
 
1980
1989
  _is_generator: bool = False
1981
1990
  _num_inputs: int | None = None
1991
+ _app_id: str | None = None
1992
+ _function_id: str | None = None
1982
1993
 
1983
1994
  def _invocation(self):
1984
1995
  return _Invocation(self.client.stub, self.object_id, self.client)
1985
1996
 
1997
+ async def _hydrate_from_id_metadata(self) -> None:
1998
+ """Hydrate metadata only when needed for FunctionCall fields."""
1999
+ request = api_pb2.FunctionCallFromIdRequest(function_call_id=self.object_id)
2000
+ resp = await self.client.stub.FunctionCallFromId(request)
2001
+ self._hydrate_metadata(resp)
2002
+
1986
2003
  @live_method
1987
2004
  async def num_inputs(self) -> int:
1988
2005
  """Get the number of inputs in the function call.
@@ -1991,9 +2008,8 @@ class _FunctionCall(typing.Generic[ReturnType], _Object, type_prefix="fc"):
1991
2008
  How many inputs this function call includes (e.g. `1` for `.spawn()`, more for `.spawn_map()`).
1992
2009
  """
1993
2010
  if self._num_inputs is None:
1994
- request = api_pb2.FunctionCallFromIdRequest(function_call_id=self.object_id)
1995
- resp = await self.client.stub.FunctionCallFromId(request)
1996
- self._num_inputs = resp.num_inputs # cached
2011
+ await self._hydrate_from_id_metadata()
2012
+ assert self._num_inputs is not None
1997
2013
  return self._num_inputs
1998
2014
 
1999
2015
  @live_method
@@ -2135,6 +2151,13 @@ class _FunctionCall(typing.Generic[ReturnType], _Object, type_prefix="fc"):
2135
2151
  )
2136
2152
  return typing.cast("modal.functions.FunctionCall[Any]", synchronizer._translate_out(impl_instance))
2137
2153
 
2154
+ def _hydrate_metadata(self, metadata: Message | None):
2155
+ # Overridden concrete implementation of base class method
2156
+ if isinstance(metadata, api_pb2.FunctionCallFromIdResponse):
2157
+ self._num_inputs = metadata.num_inputs
2158
+ self._app_id = metadata.metadata.app_id or None
2159
+ self._function_id = metadata.metadata.function_id or None
2160
+
2138
2161
  @staticmethod
2139
2162
  async def gather(*function_calls: "_FunctionCall[T]") -> typing.Sequence[T]:
2140
2163
  """Wait until all Modal FunctionCall objects have results before returning.
@@ -325,7 +325,7 @@ def create_channel(
325
325
  async def create_channel_with_fallbacks(
326
326
  server_url: str,
327
327
  metadata: dict[str, str] = {},
328
- stagger_delay: float = 1.0,
328
+ stagger_delay: float = 3.0,
329
329
  ) -> grpclib.client.Channel:
330
330
  """Create a connected channel, supporting comma-separated fallback URLs.
331
331
 
modal/client.pyi CHANGED
@@ -35,7 +35,7 @@ class _Client:
35
35
  server_url: str,
36
36
  client_type: int,
37
37
  credentials: typing.Optional[tuple[str, str]],
38
- version: str = "1.5.3.dev2",
38
+ version: str = "1.5.3.dev3",
39
39
  ):
40
40
  """mdmd:hidden
41
41
  The Modal client object is not intended to be instantiated directly by users.
@@ -205,7 +205,7 @@ class Client:
205
205
  server_url: str,
206
206
  client_type: int,
207
207
  credentials: typing.Optional[tuple[str, str]],
208
- version: str = "1.5.3.dev2",
208
+ version: str = "1.5.3.dev3",
209
209
  ):
210
210
  """mdmd:hidden
211
211
  The Modal client object is not intended to be instantiated directly by users.
modal/cls.py CHANGED
@@ -86,6 +86,8 @@ def _bind_instance_method(cls: "_Cls", service_function: _Function, method_name:
86
86
 
87
87
  method_metadata = service_function._method_handle_metadata[method_name]
88
88
  new_function._hydrate(service_function.object_id, service_function.client, method_metadata)
89
+ if not new_function._app_id:
90
+ new_function._app_id = service_function._app_id
89
91
 
90
92
  async def _load(fun: "_Function", resolver: Resolver, load_context: LoadContext, existing_object_id: str | None):
91
93
  # there is currently no actual loading logic executed to create each method on
@@ -426,6 +428,7 @@ class _Obj:
426
428
  )
427
429
  await resolver.load(method_function, load_context) # get the appropriate method handle (lazy)
428
430
  fun._hydrate_from_other(method_function)
431
+ fun._app_id = method_function._app_id
429
432
 
430
433
  # The reason we don't *always* use this lazy loader is because it precludes attribute access
431
434
  # on local classes.
modal/config.py CHANGED
@@ -106,7 +106,8 @@ from modal_proto import api_pb2
106
106
  from ._utils.logger import configure_logger
107
107
  from .exception import InvalidError, NotFoundError
108
108
 
109
- DEFAULT_SERVER_URL = "https://api.modal.com" # TODO(erikbern): add modal2.com
109
+ # By default, try api.modal.com and fail over to api.modal2.com
110
+ DEFAULT_SERVER_URL = "https://api.modal.com,https://api.modal2.com"
110
111
 
111
112
 
112
113
  # Locate config file and read it
modal/functions.pyi CHANGED
@@ -58,6 +58,7 @@ class Function(
58
58
  _metadata: typing.Optional[modal_proto.api_pb2.FunctionHandleMetadata]
59
59
  _options: modal._function_variants._FunctionOptions
60
60
  _base_function: typing.Optional[Function]
61
+ _app_id: typing.Optional[str]
61
62
 
62
63
  def __init__(self, *args, **kwargs):
63
64
  """mdmd:hidden"""
@@ -492,7 +493,7 @@ class Function(
492
493
 
493
494
  _call_generator: ___call_generator_spec
494
495
 
495
- class __remote_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER]):
496
+ class __remote_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
496
497
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER:
497
498
  """Calls the function remotely, executing it with the given arguments and returning the execution's result.
498
499
 
@@ -517,7 +518,7 @@ class Function(
517
518
  """
518
519
  ...
519
520
 
520
- remote: __remote_spec[modal._functions.P, modal._functions.ReturnType]
521
+ remote: __remote_spec[modal._functions.ReturnType, modal._functions.P]
521
522
 
522
523
  class __remote_gen_spec(typing_extensions.Protocol):
523
524
  def __call__(self, /, *args, **kwargs) -> typing.Generator[typing.Any, None, None]:
@@ -567,7 +568,7 @@ class Function(
567
568
  """
568
569
  ...
569
570
 
570
- class ___experimental_spawn_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER]):
571
+ class ___experimental_spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
571
572
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]:
572
573
  """[Experimental] Calls the function with the given arguments, without waiting for the results.
573
574
 
@@ -600,7 +601,7 @@ class Function(
600
601
  """
601
602
  ...
602
603
 
603
- _experimental_spawn: ___experimental_spawn_spec[modal._functions.P, modal._functions.ReturnType]
604
+ _experimental_spawn: ___experimental_spawn_spec[modal._functions.ReturnType, modal._functions.P]
604
605
 
605
606
  class ___spawn_map_inner_spec(typing_extensions.Protocol[P_INNER]):
606
607
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> None: ...
@@ -608,7 +609,7 @@ class Function(
608
609
 
609
610
  _spawn_map_inner: ___spawn_map_inner_spec[modal._functions.P]
610
611
 
611
- class __spawn_spec(typing_extensions.Protocol[P_INNER, ReturnType_INNER]):
612
+ class __spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
612
613
  def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]:
613
614
  """Calls the function with the given arguments, without waiting for the results.
614
615
 
@@ -641,7 +642,7 @@ class Function(
641
642
  """
642
643
  ...
643
644
 
644
- spawn: __spawn_spec[modal._functions.P, modal._functions.ReturnType]
645
+ spawn: __spawn_spec[modal._functions.ReturnType, modal._functions.P]
645
646
 
646
647
  def get_raw_f(self) -> collections.abc.Callable[..., typing.Any]:
647
648
  """Return the inner Python object wrapped by this Modal Function.
@@ -892,6 +893,8 @@ class FunctionCall(typing.Generic[modal._functions.ReturnType], modal.object.Obj
892
893
 
893
894
  _is_generator: bool
894
895
  _num_inputs: typing.Optional[int]
896
+ _app_id: typing.Optional[str]
897
+ _function_id: typing.Optional[str]
895
898
 
896
899
  def __init__(self, *args, **kwargs):
897
900
  """mdmd:hidden"""
@@ -899,6 +902,17 @@ class FunctionCall(typing.Generic[modal._functions.ReturnType], modal.object.Obj
899
902
 
900
903
  def _invocation(self): ...
901
904
 
905
+ class ___hydrate_from_id_metadata_spec(typing_extensions.Protocol):
906
+ def __call__(self, /) -> None:
907
+ """Hydrate metadata only when needed for FunctionCall fields."""
908
+ ...
909
+
910
+ async def aio(self, /) -> None:
911
+ """Hydrate metadata only when needed for FunctionCall fields."""
912
+ ...
913
+
914
+ _hydrate_from_id_metadata: ___hydrate_from_id_metadata_spec
915
+
902
916
  class __num_inputs_spec(typing_extensions.Protocol):
903
917
  def __call__(self, /) -> int:
904
918
  """Get the number of inputs in the function call.
@@ -1115,6 +1129,8 @@ class FunctionCall(typing.Generic[modal._functions.ReturnType], modal.object.Obj
1115
1129
 
1116
1130
  from_id: typing.ClassVar[__from_id_spec]
1117
1131
 
1132
+ def _hydrate_metadata(self, metadata: typing.Optional[google.protobuf.message.Message]): ...
1133
+
1118
1134
  class __gather_spec(typing_extensions.Protocol):
1119
1135
  def __call__(self, /, *function_calls: FunctionCall[modal._functions.T]) -> typing.Sequence[modal._functions.T]:
1120
1136
  """Wait until all Modal FunctionCall objects have results before returning.
modal/sandbox.py CHANGED
@@ -349,7 +349,7 @@ class _Sandbox(_Object, type_prefix="sb"):
349
349
  gpu: str | None = None,
350
350
  cloud: str | None = None,
351
351
  region: str | Sequence[str] | None = None,
352
- cpu: float | None = None,
352
+ cpu: float | tuple[float, float] | None = None,
353
353
  memory: int | tuple[int, int] | None = None,
354
354
  mounts: Sequence[_Mount] = (),
355
355
  network_file_systems: dict[str | os.PathLike, _NetworkFileSystem] = {},
@@ -823,8 +823,8 @@ class _Sandbox(_Object, type_prefix="sb"):
823
823
  timeout: int = 300,
824
824
  idle_timeout: int | None = None,
825
825
  workdir: str | None = None,
826
- cpu: float | None = None,
827
- memory: int | None = None,
826
+ cpu: float | tuple[float, float] | None = None,
827
+ memory: int | tuple[int, int] | None = None,
828
828
  cloud: str | None = None,
829
829
  region: str | Sequence[str] | None = None,
830
830
  block_network: bool = False,
@@ -852,6 +852,10 @@ class _Sandbox(_Object, type_prefix="sb"):
852
852
  `secret=...` or `oidc_auth_role_arn`), OIDC identity tokens, proxies, and
853
853
  filesystem snapshots.
854
854
 
855
+ `cpu` and `memory` accept either a scalar request or a `(request, limit)`
856
+ tuple that additionally sets a hard limit (fractional CPU cores; memory
857
+ in MiB), matching `Sandbox.create()`.
858
+
855
859
  Features like memory snapshots, network file systems, GPUs, and custom
856
860
  domains are not supported.
857
861
 
modal/sandbox.pyi CHANGED
@@ -165,7 +165,7 @@ class _Sandbox(modal._object._Object):
165
165
  gpu: typing.Optional[str] = None,
166
166
  cloud: typing.Optional[str] = None,
167
167
  region: typing.Union[str, collections.abc.Sequence[str], None] = None,
168
- cpu: typing.Optional[float] = None,
168
+ cpu: typing.Union[float, tuple[float, float], None] = None,
169
169
  memory: typing.Union[int, tuple[int, int], None] = None,
170
170
  mounts: collections.abc.Sequence[modal.mount._Mount] = (),
171
171
  network_file_systems: dict[typing.Union[str, os.PathLike], modal.network_file_system._NetworkFileSystem] = {},
@@ -368,8 +368,8 @@ class _Sandbox(modal._object._Object):
368
368
  timeout: int = 300,
369
369
  idle_timeout: typing.Optional[int] = None,
370
370
  workdir: typing.Optional[str] = None,
371
- cpu: typing.Optional[float] = None,
372
- memory: typing.Optional[int] = None,
371
+ cpu: typing.Union[float, tuple[float, float], None] = None,
372
+ memory: typing.Union[int, tuple[int, int], None] = None,
373
373
  cloud: typing.Optional[str] = None,
374
374
  region: typing.Union[str, collections.abc.Sequence[str], None] = None,
375
375
  block_network: bool = False,
@@ -400,6 +400,10 @@ class _Sandbox(modal._object._Object):
400
400
  `secret=...` or `oidc_auth_role_arn`), OIDC identity tokens, proxies, and
401
401
  filesystem snapshots.
402
402
 
403
+ `cpu` and `memory` accept either a scalar request or a `(request, limit)`
404
+ tuple that additionally sets a hard limit (fractional CPU cores; memory
405
+ in MiB), matching `Sandbox.create()`.
406
+
403
407
  Features like memory snapshots, network file systems, GPUs, and custom
404
408
  domains are not supported.
405
409
 
@@ -1337,7 +1341,7 @@ class Sandbox(modal.object.Object):
1337
1341
  gpu: typing.Optional[str] = None,
1338
1342
  cloud: typing.Optional[str] = None,
1339
1343
  region: typing.Union[str, collections.abc.Sequence[str], None] = None,
1340
- cpu: typing.Optional[float] = None,
1344
+ cpu: typing.Union[float, tuple[float, float], None] = None,
1341
1345
  memory: typing.Union[int, tuple[int, int], None] = None,
1342
1346
  mounts: collections.abc.Sequence[modal.mount.Mount] = (),
1343
1347
  network_file_systems: dict[typing.Union[str, os.PathLike], modal.network_file_system.NetworkFileSystem] = {},
@@ -1721,8 +1725,8 @@ class Sandbox(modal.object.Object):
1721
1725
  timeout: int = 300,
1722
1726
  idle_timeout: typing.Optional[int] = None,
1723
1727
  workdir: typing.Optional[str] = None,
1724
- cpu: typing.Optional[float] = None,
1725
- memory: typing.Optional[int] = None,
1728
+ cpu: typing.Union[float, tuple[float, float], None] = None,
1729
+ memory: typing.Union[int, tuple[int, int], None] = None,
1726
1730
  cloud: typing.Optional[str] = None,
1727
1731
  region: typing.Union[str, collections.abc.Sequence[str], None] = None,
1728
1732
  block_network: bool = False,
@@ -1753,6 +1757,10 @@ class Sandbox(modal.object.Object):
1753
1757
  `secret=...` or `oidc_auth_role_arn`), OIDC identity tokens, proxies, and
1754
1758
  filesystem snapshots.
1755
1759
 
1760
+ `cpu` and `memory` accept either a scalar request or a `(request, limit)`
1761
+ tuple that additionally sets a hard limit (fractional CPU cores; memory
1762
+ in MiB), matching `Sandbox.create()`.
1763
+
1756
1764
  Features like memory snapshots, network file systems, GPUs, and custom
1757
1765
  domains are not supported.
1758
1766
 
@@ -1783,8 +1791,8 @@ class Sandbox(modal.object.Object):
1783
1791
  timeout: int = 300,
1784
1792
  idle_timeout: typing.Optional[int] = None,
1785
1793
  workdir: typing.Optional[str] = None,
1786
- cpu: typing.Optional[float] = None,
1787
- memory: typing.Optional[int] = None,
1794
+ cpu: typing.Union[float, tuple[float, float], None] = None,
1795
+ memory: typing.Union[int, tuple[int, int], None] = None,
1788
1796
  cloud: typing.Optional[str] = None,
1789
1797
  region: typing.Union[str, collections.abc.Sequence[str], None] = None,
1790
1798
  block_network: bool = False,
@@ -1815,6 +1823,10 @@ class Sandbox(modal.object.Object):
1815
1823
  `secret=...` or `oidc_auth_role_arn`), OIDC identity tokens, proxies, and
1816
1824
  filesystem snapshots.
1817
1825
 
1826
+ `cpu` and `memory` accept either a scalar request or a `(request, limit)`
1827
+ tuple that additionally sets a hard limit (fractional CPU cores; memory
1828
+ in MiB), matching `Sandbox.create()`.
1829
+
1818
1830
  Features like memory snapshots, network file systems, GPUs, and custom
1819
1831
  domains are not supported.
1820
1832
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: modal
3
- Version: 1.5.3.dev2
3
+ Version: 1.5.3.dev3
4
4
  Summary: Python client library for Modal
5
5
  Author-email: Modal Labs <support@modal.com>
6
6
  License-Expression: Apache-2.0
@@ -6,7 +6,7 @@ modal/_clustered_functions.pyi,sha256=akbff8aXkp5aJapn72YMXPnzeYa6OFAfuakcy7Jx6w
6
6
  modal/_container_entrypoint.py,sha256=RoO9tnQVsUfzuqi0QzDkYKt-1YR3qlqEUok_jGhXw2s,22822
7
7
  modal/_environments.py,sha256=fpKvtG38NqRiT-4NkBqK1DCZn5LAqPO_vznFIbTCXEE,21016
8
8
  modal/_function_variants.py,sha256=ixkwW9naMMBzRB-92BZd5k3iVWtOoYukveT52hLDIbc,12549
9
- modal/_functions.py,sha256=aav9lg_LQ-eWwUoN29ai09mLQjtLv0CpnEht2zTlc1o,94280
9
+ modal/_functions.py,sha256=MCvwVytan1PoOb9y9Usi7PUXVypsh-CiogFHzfp7WBE,95261
10
10
  modal/_grpc_client.py,sha256=QL5btzOz6zZzTDcgSwFjI3PBy2gkaycyrlP7Jw-jkbY,6962
11
11
  modal/_image.py,sha256=TW-0QiFa3Lo1w9khZcE8mgSHQgj-PJ0eChb8IkS2eqo,128738
12
12
  modal/_ipython.py,sha256=Bu9fc3hm3xt2O47qLe_d-Mu2jS81LwMsmXNJ1sawBA0,575
@@ -31,12 +31,12 @@ modal/billing.py,sha256=E1-P_P8bJFLp-bTaggYd4BaaViImPB5UdtXiY8VeAZQ,390
31
31
  modal/billing.pyi,sha256=4m7VLYNS8IiJ2I3CJx0awvrOM6BILWRVLfdeqtAYr8M,7189
32
32
  modal/call_graph.py,sha256=XGALIDn1bLchWo_goyX23bcPjzCZcfqKUo8INIfDapo,1775
33
33
  modal/client.py,sha256=OgjptM5UuU5LL85_-DFia-ehS8UCgMzVuzfNcxA1qPA,16136
34
- modal/client.pyi,sha256=TGnoJ3BoRPn-pORdwxHg3D5ZQ7_QHvdoPO8mCvyl6oo,17852
34
+ modal/client.pyi,sha256=QxUv7QBKtlylLD1LgUc3Ht7fBpHbnAlCCRWUwsAscFY,17852
35
35
  modal/cloud_bucket_mount.py,sha256=03gECcV9l2Lnt9k23YrDOTGFW7ajfXMW5O8b1prhtwQ,6254
36
36
  modal/cloud_bucket_mount.pyi,sha256=lMOb44pbNE9kDVEqWfcmvpsnh1sdNNFzuKoVyZZ3d5M,8058
37
- modal/cls.py,sha256=A4EW0VDrYtQubZJIzGoxnP1wANWD_2PMpU1Q0n8oUhU,40834
37
+ modal/cls.py,sha256=lNsIz0rm5pbayfrODwb3MVGOqNnhosWJQTFpVLfjJvk,40981
38
38
  modal/cls.pyi,sha256=FzYY7OkxuoqTZ-196Nsp6iC4yLud-Rq4qui_x7jxNzc,29421
39
- modal/config.py,sha256=vSJK_IB5Mc3msvRJc1Jl84mpTBnvmhmjVBpTR0sUpEQ,15187
39
+ modal/config.py,sha256=tPH74oIFOP0jyhlCRrgZQOfUIlJz2LuFIYbLWaVmDgQ,15240
40
40
  modal/container_process.py,sha256=E2YZImDLG4vq8V_4PqEL65z_tEOpA0rzxf2190BAaA4,8403
41
41
  modal/container_process.pyi,sha256=-8UstN3w-SbKbW2qbf1OSirqDQuLBBdvJE3ysJXTWHQ,4617
42
42
  modal/dict.py,sha256=LILESg1hALZHwlW7uslbUyxc2mpgtNisEmk8xl-559Y,23953
@@ -48,7 +48,7 @@ modal/file_io.py,sha256=GYTa67mrmbTTTBsYQnb51VmwGIo0YY-1qQ3YBhagkmA,21795
48
48
  modal/file_io.pyi,sha256=3181-DS07flFWLf2BKjqCOiWIjieEOolf33wx6fBp5c,15377
49
49
  modal/file_pattern_matcher.py,sha256=6g_awxudMy_ontBvkznybyeNnwGMj297YrmIHCbREI0,8132
50
50
  modal/functions.py,sha256=EZRcHFfnoYbvawUJnAHF5nIvoo9GX2Djy7mUmOCXmXc,258
51
- modal/functions.pyi,sha256=fVNoXoSs7GJCoQUCpfWAd50iGdmByH0y62mQYM0DpE8,47643
51
+ modal/functions.pyi,sha256=lLFJQ-jgPuYu1F7ZO95fRZE5bftwyd5alEDGAs8N6D4,48252
52
52
  modal/image.py,sha256=c0lUSAoU-Ip3g5DGZ0uhdCzoWSQWh1g0i-7Rxo-Sz-I,160
53
53
  modal/image.pyi,sha256=Whbfmda2YLAyzctLEF9uF4FQ5b1canwLojSksRJ4gx8,59716
54
54
  modal/io_streams.py,sha256=3fhhb7SDJ69pVUu9J3PiMLBePD9bpiIxPN05SCzf8FE,29118
@@ -73,8 +73,8 @@ modal/retries.py,sha256=tSGB5bGM5xZZUDXMkuelIEoQJY0vOukOssZhwc6tXAo,5014
73
73
  modal/runner.py,sha256=YdBqWOWkcGgSDKLEz1zrGNHrh0-d2tSNx24XPB6QyoM,30284
74
74
  modal/runner.pyi,sha256=0hIfkl-7VTyw1n-1B0AV7f53t3i3hCzRPyBu3DUyHnk,9669
75
75
  modal/running_app.py,sha256=xSR1VVlhxEFytmjx2x697_0GpD25Vc9crhp6r117_QY,1145
76
- modal/sandbox.py,sha256=AJNYMyXXCcPF7LR9FwtvqAPzzFp_GHlNDiq9jlOSx-I,113601
77
- modal/sandbox.pyi,sha256=xFjtHUn_jb_V37dOS91eW5q97TrwlairxQUAH6J3ZZQ,134361
76
+ modal/sandbox.py,sha256=13RYT10MFNqbPTAk0Tt09qBxDm9vIWPy8tko-BBv6Io,113872
77
+ modal/sandbox.pyi,sha256=Lkb0GdLoMPT_NrAy3hR0hmzWL1ABlHEdRhwkAp4CcPI,135192
78
78
  modal/sandbox_fs.py,sha256=MkDTAiboDdnMYf34TSz9LHGc1sqpmAIXRdr9X3x2bno,29780
79
79
  modal/sandbox_fs.pyi,sha256=wWPqovzu4GcPPWl06yKwvyvgqjM_JvLnmbq0tZrnLlQ,44481
80
80
  modal/schedule.py,sha256=3F15Vh4g8C34jGcO-vgFkBHZl7XvP7qieXayQ9gKsyw,3248
@@ -125,7 +125,7 @@ modal/_utils/docker_utils.py,sha256=k8fkYT6G-X_B3iamjxiSpwSE-k58xGVHtsk2_gR7i2Q,
125
125
  modal/_utils/function_utils.py,sha256=2aTsjOt-GWm7S1LprAUs-thzxzFSsjtoZdWsgWXFfag,25303
126
126
  modal/_utils/git_utils.py,sha256=Lat_l4O4hwOYgylEtWup3hyqWT8D7JoCIjCflXcX8BE,3148
127
127
  modal/_utils/grpc_testing.py,sha256=udyK_wRXX_yc9eLt8mIZZqx12XlaiUqORxaGNvfI_MM,8697
128
- modal/_utils/grpc_utils.py,sha256=07jQHcAxt7uRjqZiu35gVn8fqBMu18RxKY97EpyPPxU,23715
128
+ modal/_utils/grpc_utils.py,sha256=EYPxZe12kMudSf-y3JuOvXHIa8vANb_sk65Ve0FP0uw,23715
129
129
  modal/_utils/hash_utils.py,sha256=WHuMRwmB4fnaM-qmyWXR87C2CinvLnmRoygSzsTEunA,3008
130
130
  modal/_utils/http_utils.py,sha256=TO9nnKR0Cc-iWCmkou56wJh9MHgNZwQMosK8WK-GD5Y,3133
131
131
  modal/_utils/jwt_utils.py,sha256=KUoqGHMM4ewDyTsTKXPm1wrMu8Z6lp0l8VILHufm484,1354
@@ -194,7 +194,7 @@ modal/experimental/flash.py,sha256=GAJ1c-EGL8M3_loAkqr5gdUfySMHY3U_oc6RywfZ8-0,3
194
194
  modal/experimental/flash.pyi,sha256=lpTqJFZRMGWscw0xpYZVdBMnAYjj16asXE4_64A6itQ,17774
195
195
  modal/experimental/ipython.py,sha256=kJ6o9wkAY_MiSb7paewI7f1MJAeqdi8TX5pBdhr_mUI,2925
196
196
  modal/skills/modal/SKILL.md,sha256=WzLjYJ1utjc_ZOf6qZTPwB6wxxwRYB5PibdvIf_FLy0,5316
197
- modal-1.5.3.dev2.dist-info/licenses/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
197
+ modal-1.5.3.dev3.dist-info/licenses/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
198
198
  modal_docs/__init__.py,sha256=svYKtV8HDwDCN86zbdWqyq5T8sMdGDj0PVlzc2tIxDM,28
199
199
  modal_docs/gen_cli_docs.py,sha256=9-b8vl2EsLWD9zJqpCK8IUi5h44Bjn3i3rSdedZV4bA,6415
200
200
  modal_docs/gen_cli_docs_main.py,sha256=UPGr7O1DYTIRLwfINe2rbdh89J3cPVTU1OWL-SjxnOQ,198
@@ -205,22 +205,22 @@ modal_docs/mdmd/mdmd.py,sha256=MmoDhKpA-YKXgJW-pdVqgKN0Wizoxl91q-RkHFPZ9iA,24738
205
205
  modal_docs/mdmd/signatures.py,sha256=OASroKle763Kfumn4Ek4PABJXEGP56JMCTug44QoBx4,11327
206
206
  modal_docs/mdmd/types.py,sha256=MIh5VOnWvFd8T1aZT_vTB2OeLbPB5TASdOaX8jGvpQk,710
207
207
  modal_proto/__init__.py,sha256=tFdSv9eaHBvYcwhgq-XqIlYDNDw57clrvO91Fb-oUV4,130
208
- modal_proto/api_grpc.py,sha256=A8qITFFpfpC7vGee-0TChck4CsuKQMhoUeK3kujcszQ,179126
209
- modal_proto/api_pb2.py,sha256=InjqGNbsfXuy90hsJsNoGFVcmnfDcmnwocuw-RnP_vM,487472
210
- modal_proto/api_pb2.pyi,sha256=IgGZYgYSojw-Fj8fydD1GeFRsOzZ1FRw7z9qSUD1Mks,675099
211
- modal_proto/api_pb2_grpc.py,sha256=nq8fa0wvpAZKFWOM6AEdQFgmM3SqGJN6UWKEVeExor4,384710
212
- modal_proto/api_pb2_grpc.pyi,sha256=SxXg2mPSzMYODtRmE_GPZA4u7qYaa4_jVTahZU5h_pk,89930
213
- modal_proto/modal_api_grpc.py,sha256=oVMWQ-xpX82WwNl5K0nN9kNS0rfcgTd7hcfqufGu__A,28261
208
+ modal_proto/api_grpc.py,sha256=CjYf63JrYWgg4cw-vq-PfwfI-CKLzFijhHLqO6XtiLw,179894
209
+ modal_proto/api_pb2.py,sha256=GwIhl4I5PgGPXHUlZsdTNAeDe5d87Brm8cuWj75F7Hs,490101
210
+ modal_proto/api_pb2.pyi,sha256=Iaq2wlsV83mckDZNL6gdBm9sYIEjdJeEgJMwn3qe0OY,677375
211
+ modal_proto/api_pb2_grpc.py,sha256=jhCqkV4rVo5ElpBJj_MvgJdCheR03R4vmH8fFsIjCJQ,386369
212
+ modal_proto/api_pb2_grpc.pyi,sha256=Ye-hXvCtMciQ5DG9-7_-dZLvR3Ugp7_VwHNOBwYiZmU,90307
213
+ modal_proto/modal_api_grpc.py,sha256=jvnQeJ3KS7nK0W6K0cvizuWWcHuaTnUewHCrDgIRsH0,28377
214
214
  modal_proto/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
215
215
  modal_proto/task_command_router_grpc.py,sha256=w6FRgxm5wtCXtUL4m1A-57wwhhucxuz6AIlZBZjfaMM,20338
216
216
  modal_proto/task_command_router_pb2.py,sha256=LoHxWrzF0EV_gG6SKtAXZbxLUjI-AXzCIGkyuVzTBiE,39470
217
217
  modal_proto/task_command_router_pb2.pyi,sha256=mT-KTIZlLJ5Hd0mXSxyXw84pt_7tV__hd5TpHJ4OHh4,44044
218
218
  modal_proto/task_command_router_pb2_grpc.py,sha256=bX22HJ8qEqKl5YkP00-EPE83rZUdqmk0FDZjtpb21-U,40487
219
219
  modal_proto/task_command_router_pb2_grpc.pyi,sha256=DnkJ4U5hq6wp7XkLyE9xELNqSmNwA_vgawTiS_fVBK0,13241
220
- modal_version/__init__.py,sha256=0bxB0DrvR3i4nk6WAxNy7MXXkcQsVIQjgDKtlq8RanA,120
220
+ modal_version/__init__.py,sha256=dLtW8kK2bH2LLjpA_vD95vNh_cZy_8wMTnyloLNzmec,120
221
221
  modal_version/__main__.py,sha256=nLUbubxKx7GXNzJIkTB7M7_u8080LyLM0IS0rzFkC_c,119
222
- modal-1.5.3.dev2.dist-info/METADATA,sha256=Io_zAgMXDC-K_dNiDl2q0puMwD0ijM2JmXNYBFCzu3o,2512
223
- modal-1.5.3.dev2.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
224
- modal-1.5.3.dev2.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
225
- modal-1.5.3.dev2.dist-info/top_level.txt,sha256=4BWzoKYREKUZ5iyPzZpjqx4G8uB5TWxXPDwibLcVa7k,43
226
- modal-1.5.3.dev2.dist-info/RECORD,,
222
+ modal-1.5.3.dev3.dist-info/METADATA,sha256=qmVmXOHP69FJsxbpGnhzrd2LKssjgRuCIyRz59f4yXM,2512
223
+ modal-1.5.3.dev3.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
224
+ modal-1.5.3.dev3.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
225
+ modal-1.5.3.dev3.dist-info/top_level.txt,sha256=4BWzoKYREKUZ5iyPzZpjqx4G8uB5TWxXPDwibLcVa7k,43
226
+ modal-1.5.3.dev3.dist-info/RECORD,,
modal_proto/api_grpc.py CHANGED
@@ -639,6 +639,10 @@ class ModalClientBase(abc.ABC):
639
639
  async def SandboxRestore(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxRestoreRequest, modal_proto.api_pb2.SandboxRestoreResponse]') -> None:
640
640
  pass
641
641
 
642
+ @abc.abstractmethod
643
+ async def SandboxSetName(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxSetNameRequest, modal_proto.api_pb2.SandboxSetNameResponse]') -> None:
644
+ pass
645
+
642
646
  @abc.abstractmethod
643
647
  async def SandboxSnapshot(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxSnapshotRequest, modal_proto.api_pb2.SandboxSnapshotResponse]') -> None:
644
648
  pass
@@ -1871,6 +1875,12 @@ class ModalClientBase(abc.ABC):
1871
1875
  modal_proto.api_pb2.SandboxRestoreRequest,
1872
1876
  modal_proto.api_pb2.SandboxRestoreResponse,
1873
1877
  ),
1878
+ '/modal.client.ModalClient/SandboxSetName': grpclib.const.Handler(
1879
+ self.SandboxSetName,
1880
+ grpclib.const.Cardinality.UNARY_UNARY,
1881
+ modal_proto.api_pb2.SandboxSetNameRequest,
1882
+ modal_proto.api_pb2.SandboxSetNameResponse,
1883
+ ),
1874
1884
  '/modal.client.ModalClient/SandboxSnapshot': grpclib.const.Handler(
1875
1885
  self.SandboxSnapshot,
1876
1886
  grpclib.const.Cardinality.UNARY_UNARY,
@@ -3257,6 +3267,12 @@ class ModalClientStub:
3257
3267
  modal_proto.api_pb2.SandboxRestoreRequest,
3258
3268
  modal_proto.api_pb2.SandboxRestoreResponse,
3259
3269
  )
3270
+ self.SandboxSetName = grpclib.client.UnaryUnaryMethod(
3271
+ channel,
3272
+ '/modal.client.ModalClient/SandboxSetName',
3273
+ modal_proto.api_pb2.SandboxSetNameRequest,
3274
+ modal_proto.api_pb2.SandboxSetNameResponse,
3275
+ )
3260
3276
  self.SandboxSnapshot = grpclib.client.UnaryUnaryMethod(
3261
3277
  channel,
3262
3278
  '/modal.client.ModalClient/SandboxSnapshot',