modal 0.72.25__py3-none-any.whl → 0.72.27__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 +2 -2
- modal/functions.pyi +6 -6
- {modal-0.72.25.dist-info → modal-0.72.27.dist-info}/METADATA +1 -1
- {modal-0.72.25.dist-info → modal-0.72.27.dist-info}/RECORD +16 -16
- modal_proto/api.proto +41 -1
- modal_proto/api_grpc.py +48 -0
- modal_proto/api_pb2.py +406 -344
- modal_proto/api_pb2.pyi +122 -10
- modal_proto/api_pb2_grpc.py +99 -0
- modal_proto/api_pb2_grpc.pyi +30 -0
- modal_proto/modal_api_grpc.py +3 -0
- modal_version/_version_generated.py +1 -1
- {modal-0.72.25.dist-info → modal-0.72.27.dist-info}/LICENSE +0 -0
- {modal-0.72.25.dist-info → modal-0.72.27.dist-info}/WHEEL +0 -0
- {modal-0.72.25.dist-info → modal-0.72.27.dist-info}/entry_points.txt +0 -0
- {modal-0.72.25.dist-info → modal-0.72.27.dist-info}/top_level.txt +0 -0
modal/client.pyi
CHANGED
@@ -27,7 +27,7 @@ class _Client:
|
|
27
27
|
_snapshotted: bool
|
28
28
|
|
29
29
|
def __init__(
|
30
|
-
self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.72.
|
30
|
+
self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.72.27"
|
31
31
|
): ...
|
32
32
|
def is_closed(self) -> bool: ...
|
33
33
|
@property
|
@@ -83,7 +83,7 @@ class Client:
|
|
83
83
|
_snapshotted: bool
|
84
84
|
|
85
85
|
def __init__(
|
86
|
-
self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.72.
|
86
|
+
self, server_url: str, client_type: int, credentials: typing.Optional[tuple[str, str]], version: str = "0.72.27"
|
87
87
|
): ...
|
88
88
|
def is_closed(self) -> bool: ...
|
89
89
|
@property
|
modal/functions.pyi
CHANGED
@@ -463,11 +463,11 @@ class Function(typing.Generic[P, ReturnType, OriginalReturnType], modal.object.O
|
|
463
463
|
|
464
464
|
_call_generator_nowait: ___call_generator_nowait_spec
|
465
465
|
|
466
|
-
class __remote_spec(typing_extensions.Protocol[
|
466
|
+
class __remote_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
|
467
467
|
def __call__(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER: ...
|
468
468
|
async def aio(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER: ...
|
469
469
|
|
470
|
-
remote: __remote_spec[
|
470
|
+
remote: __remote_spec[ReturnType, P]
|
471
471
|
|
472
472
|
class __remote_gen_spec(typing_extensions.Protocol):
|
473
473
|
def __call__(self, *args, **kwargs) -> typing.Generator[typing.Any, None, None]: ...
|
@@ -480,17 +480,17 @@ class Function(typing.Generic[P, ReturnType, OriginalReturnType], modal.object.O
|
|
480
480
|
def _get_obj(self) -> typing.Optional[modal.cls.Obj]: ...
|
481
481
|
def local(self, *args: P.args, **kwargs: P.kwargs) -> OriginalReturnType: ...
|
482
482
|
|
483
|
-
class ___experimental_spawn_spec(typing_extensions.Protocol[
|
483
|
+
class ___experimental_spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
|
484
484
|
def __call__(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
|
485
485
|
async def aio(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
|
486
486
|
|
487
|
-
_experimental_spawn: ___experimental_spawn_spec[
|
487
|
+
_experimental_spawn: ___experimental_spawn_spec[ReturnType, P]
|
488
488
|
|
489
|
-
class __spawn_spec(typing_extensions.Protocol[
|
489
|
+
class __spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER]):
|
490
490
|
def __call__(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
|
491
491
|
async def aio(self, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]: ...
|
492
492
|
|
493
|
-
spawn: __spawn_spec[
|
493
|
+
spawn: __spawn_spec[ReturnType, P]
|
494
494
|
|
495
495
|
def get_raw_f(self) -> typing.Callable[..., typing.Any]: ...
|
496
496
|
|
@@ -20,7 +20,7 @@ modal/app.py,sha256=UOuqlCKlFAjOXCacXmoEMM90FnqFwPRXUhLh0Gi6xzg,45344
|
|
20
20
|
modal/app.pyi,sha256=5D3LkPP6qvTIl2_YgiyhNQ9X4VsOVuxd69a23UmohDg,25477
|
21
21
|
modal/call_graph.py,sha256=1g2DGcMIJvRy-xKicuf63IVE98gJSnQsr8R_NVMptNc,2581
|
22
22
|
modal/client.py,sha256=8SQawr7P1PNUCq1UmJMUQXG2jIo4Nmdcs311XqrNLRE,15276
|
23
|
-
modal/client.pyi,sha256=
|
23
|
+
modal/client.pyi,sha256=3bLlslVmbEVRR-_1oOOdWxtMLgWoZiAp9tjSHFF95b0,7326
|
24
24
|
modal/cloud_bucket_mount.py,sha256=G7T7jWLD0QkmrfKR75mSTwdUZ2xNfj7pkVqb4ipmxmI,5735
|
25
25
|
modal/cloud_bucket_mount.pyi,sha256=CEi7vrH3kDUF4LAy4qP6tfImy2UJuFRcRbsgRNM1wo8,1403
|
26
26
|
modal/cls.py,sha256=xHgZZAmymplw0I2YZGAA8raBboixdNKKTrnsxQZI7G8,32159
|
@@ -38,7 +38,7 @@ modal/file_io.py,sha256=lcMs_E9Xfm0YX1t9U2wNIBPnqHRxmImqjLW1GHqVmyg,20945
|
|
38
38
|
modal/file_io.pyi,sha256=NrIoB0YjIqZ8MDMe826xAnybT0ww_kxQM3iPLo82REU,8898
|
39
39
|
modal/file_pattern_matcher.py,sha256=dSo7BMQGZBAuoBFOX-e_72HxmF3FLzjQlEtnGtJiaD4,6506
|
40
40
|
modal/functions.py,sha256=IP-6oHMmt-wUJPBWJ7Y7Vw2vqk2bYFRSQmV38T2STTI,68371
|
41
|
-
modal/functions.pyi,sha256=
|
41
|
+
modal/functions.pyi,sha256=EcGd1uGnJVbnMmdsnANYeDjLzjaL8BREG3XgxaDPcvM,25473
|
42
42
|
modal/gpu.py,sha256=MTxj6ql8EpgfBg8YmZ5a1cLznyuZFssX1qXbEX4LKVM,7503
|
43
43
|
modal/image.py,sha256=leeY7fLfFjS0IqTi3D4cRxIDOb80BPtb3jsQfqvVJ8c,90912
|
44
44
|
modal/image.pyi,sha256=X9vj6cwBdYh8q_2cOd-2RSYNMF49ujcy0lrOXh_v1xc,26049
|
@@ -149,13 +149,13 @@ modal_global_objects/mounts/__init__.py,sha256=MIEP8jhXUeGq_eCjYFcqN5b1bxBM4fdk0
|
|
149
149
|
modal_global_objects/mounts/modal_client_package.py,sha256=W0E_yShsRojPzWm6LtIQqNVolapdnrZkm2hVEQuZK_4,767
|
150
150
|
modal_global_objects/mounts/python_standalone.py,sha256=pEML5GaV2_0ahci_1vpfc_FnySpsfi2fhYmFF5I7IiQ,1837
|
151
151
|
modal_proto/__init__.py,sha256=MIEP8jhXUeGq_eCjYFcqN5b1bxBM4fdk0VESpjWR0fc,28
|
152
|
-
modal_proto/api.proto,sha256=
|
153
|
-
modal_proto/api_grpc.py,sha256=
|
154
|
-
modal_proto/api_pb2.py,sha256=
|
155
|
-
modal_proto/api_pb2.pyi,sha256=
|
156
|
-
modal_proto/api_pb2_grpc.py,sha256=
|
157
|
-
modal_proto/api_pb2_grpc.pyi,sha256=
|
158
|
-
modal_proto/modal_api_grpc.py,sha256=
|
152
|
+
modal_proto/api.proto,sha256=307yBulNJZxQHq4kLX8Yj1eHayoUbG2YcIG-o2wpl5g,84046
|
153
|
+
modal_proto/api_grpc.py,sha256=Bcgo5hmJ0FCAVvWAm7X7Qki2GZ2gvAu3kOtqzRtvoMc,106793
|
154
|
+
modal_proto/api_pb2.py,sha256=hJUJMzvR6jbnM-Mizf_7th7nAoWWvweoSvtuKYuO6XA,307028
|
155
|
+
modal_proto/api_pb2.pyi,sha256=lxnLtONZBKfxkNh0jo2uHrLfmf-jUPNfVa4paZIqO34,409936
|
156
|
+
modal_proto/api_pb2_grpc.py,sha256=OTPQgFBajKwy7fhAFEewDjY6lK49C60Z9vTqUpQy_oY,230822
|
157
|
+
modal_proto/api_pb2_grpc.pyi,sha256=mwP2mw6UE46CHlraqicXHsgyGPtV0mCy96LwnFMz74s,53787
|
158
|
+
modal_proto/modal_api_grpc.py,sha256=C5QcdsBWEvF9ufbEjdyPQ5IDDexMdAI2_CQ_U2nEYuc,14258
|
159
159
|
modal_proto/modal_options_grpc.py,sha256=qJ1cuwA54oRqrdTyPTbvfhFZYd9HhJKK5UCwt523r3Y,120
|
160
160
|
modal_proto/options.proto,sha256=a-siq4swVbZPfaFRXAipRZzGP2bq8OsdUvjlyzAeodQ,488
|
161
161
|
modal_proto/options_grpc.py,sha256=M18X3d-8F_cNYSVM3I25dUTO5rZ0rd-vCCfynfh13Nc,125
|
@@ -166,10 +166,10 @@ modal_proto/options_pb2_grpc.pyi,sha256=CImmhxHsYnF09iENPoe8S4J-n93jtgUYD2JPAc0y
|
|
166
166
|
modal_proto/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
167
167
|
modal_version/__init__.py,sha256=kGya2ZlItX2zB7oHORs-wvP4PG8lg_mtbi1QIK3G6SQ,470
|
168
168
|
modal_version/__main__.py,sha256=2FO0yYQQwDTh6udt1h-cBnGd1c4ZyHnHSI4BksxzVac,105
|
169
|
-
modal_version/_version_generated.py,sha256=
|
170
|
-
modal-0.72.
|
171
|
-
modal-0.72.
|
172
|
-
modal-0.72.
|
173
|
-
modal-0.72.
|
174
|
-
modal-0.72.
|
175
|
-
modal-0.72.
|
169
|
+
modal_version/_version_generated.py,sha256=lj6XlIC7owYbmQpzTGNF1jA1FSxMHqSX0HdPqr7S8fc,149
|
170
|
+
modal-0.72.27.dist-info/LICENSE,sha256=psuoW8kuDP96RQsdhzwOqi6fyWv0ct8CR6Jr7He_P_k,10173
|
171
|
+
modal-0.72.27.dist-info/METADATA,sha256=OLf58w13HmbaispDy6GCMT0weQ7RtxbTnwa0tlLJMqQ,2329
|
172
|
+
modal-0.72.27.dist-info/WHEEL,sha256=G16H4A3IeoQmnOrYV4ueZGKSjhipXx8zc8nu9FGlvMA,92
|
173
|
+
modal-0.72.27.dist-info/entry_points.txt,sha256=An-wYgeEUnm6xzrAP9_NTSTSciYvvEWsMZILtYrvpAI,46
|
174
|
+
modal-0.72.27.dist-info/top_level.txt,sha256=1nvYbOSIKcmU50fNrpnQnrrOpj269ei3LzgB6j9xGqg,64
|
175
|
+
modal-0.72.27.dist-info/RECORD,,
|
modal_proto/api.proto
CHANGED
@@ -1900,7 +1900,7 @@ message NotebookKernelPublishResultsRequest {
|
|
1900
1900
|
NotebookOutput output = 2;
|
1901
1901
|
|
1902
1902
|
// Clear all previous outputs of the cell.
|
1903
|
-
bool
|
1903
|
+
bool clear_output = 3;
|
1904
1904
|
|
1905
1905
|
// Cell has finished executing, return the kernel's execute_reply.
|
1906
1906
|
ExecuteReply execute_reply = 4;
|
@@ -1927,6 +1927,9 @@ message NotebookOutput {
|
|
1927
1927
|
message DisplayData {
|
1928
1928
|
google.protobuf.Struct data = 1; // mimebundle
|
1929
1929
|
google.protobuf.Struct metadata = 2;
|
1930
|
+
|
1931
|
+
// This should not be included in saved notebook.
|
1932
|
+
optional string transient_display_id = 3;
|
1930
1933
|
}
|
1931
1934
|
|
1932
1935
|
// Stream output from a code cell (stdout / stderr).
|
@@ -2223,6 +2226,13 @@ message Sandbox {
|
|
2223
2226
|
NetworkAccess network_access = 22;
|
2224
2227
|
|
2225
2228
|
optional string proxy_id = 23;
|
2229
|
+
|
2230
|
+
// Enable memory snapshots.
|
2231
|
+
bool enable_memory_snapshot = 24;
|
2232
|
+
|
2233
|
+
// Used to pin gVisor version for memory-snapshottable sandboxes.
|
2234
|
+
// This field is set by the server, not the client.
|
2235
|
+
optional uint32 snapshot_version = 25;
|
2226
2236
|
}
|
2227
2237
|
|
2228
2238
|
message SandboxCreateRequest {
|
@@ -2287,6 +2297,16 @@ message SandboxListResponse {
|
|
2287
2297
|
repeated SandboxInfo sandboxes = 1;
|
2288
2298
|
}
|
2289
2299
|
|
2300
|
+
message SandboxRestoreRequest {
|
2301
|
+
string app_id = 1 [ (modal.options.audit_target_attr) = true ];
|
2302
|
+
string snapshot_id = 2;
|
2303
|
+
string environment_name = 3;
|
2304
|
+
}
|
2305
|
+
|
2306
|
+
message SandboxRestoreResponse {
|
2307
|
+
string sandbox_id = 1;
|
2308
|
+
}
|
2309
|
+
|
2290
2310
|
message SandboxSnapshotFsRequest {
|
2291
2311
|
string sandbox_id = 1;
|
2292
2312
|
float timeout = 2;
|
@@ -2299,6 +2319,23 @@ message SandboxSnapshotFsResponse {
|
|
2299
2319
|
ImageMetadata image_metadata = 3;
|
2300
2320
|
}
|
2301
2321
|
|
2322
|
+
message SandboxSnapshotRequest {
|
2323
|
+
string sandbox_id = 1;
|
2324
|
+
}
|
2325
|
+
|
2326
|
+
message SandboxSnapshotResponse {
|
2327
|
+
string snapshot_id = 1;
|
2328
|
+
}
|
2329
|
+
|
2330
|
+
message SandboxSnapshotWaitRequest {
|
2331
|
+
string snapshot_id = 1;
|
2332
|
+
float timeout = 2;
|
2333
|
+
}
|
2334
|
+
|
2335
|
+
message SandboxSnapshotWaitResponse {
|
2336
|
+
GenericResult result = 1;
|
2337
|
+
}
|
2338
|
+
|
2302
2339
|
message SandboxStdinWriteRequest {
|
2303
2340
|
string sandbox_id = 1;
|
2304
2341
|
bytes input = 2;
|
@@ -2921,7 +2958,10 @@ service ModalClient {
|
|
2921
2958
|
rpc SandboxGetTaskId(SandboxGetTaskIdRequest) returns (SandboxGetTaskIdResponse); // needed for modal container exec
|
2922
2959
|
rpc SandboxGetTunnels(SandboxGetTunnelsRequest) returns (SandboxGetTunnelsResponse);
|
2923
2960
|
rpc SandboxList(SandboxListRequest) returns (SandboxListResponse);
|
2961
|
+
rpc SandboxRestore(SandboxRestoreRequest) returns (SandboxRestoreResponse);
|
2962
|
+
rpc SandboxSnapshot(SandboxSnapshotRequest) returns (SandboxSnapshotResponse);
|
2924
2963
|
rpc SandboxSnapshotFs(SandboxSnapshotFsRequest) returns (SandboxSnapshotFsResponse);
|
2964
|
+
rpc SandboxSnapshotWait(SandboxSnapshotWaitRequest) returns (SandboxSnapshotWaitResponse);
|
2925
2965
|
rpc SandboxStdinWrite(SandboxStdinWriteRequest) returns (SandboxStdinWriteResponse);
|
2926
2966
|
rpc SandboxTagsSet(SandboxTagsSetRequest) returns (google.protobuf.Empty);
|
2927
2967
|
rpc SandboxTerminate(SandboxTerminateRequest) returns (SandboxTerminateResponse);
|
modal_proto/api_grpc.py
CHANGED
@@ -410,10 +410,22 @@ class ModalClientBase(abc.ABC):
|
|
410
410
|
async def SandboxList(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxListRequest, modal_proto.api_pb2.SandboxListResponse]') -> None:
|
411
411
|
pass
|
412
412
|
|
413
|
+
@abc.abstractmethod
|
414
|
+
async def SandboxRestore(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxRestoreRequest, modal_proto.api_pb2.SandboxRestoreResponse]') -> None:
|
415
|
+
pass
|
416
|
+
|
417
|
+
@abc.abstractmethod
|
418
|
+
async def SandboxSnapshot(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxSnapshotRequest, modal_proto.api_pb2.SandboxSnapshotResponse]') -> None:
|
419
|
+
pass
|
420
|
+
|
413
421
|
@abc.abstractmethod
|
414
422
|
async def SandboxSnapshotFs(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxSnapshotFsRequest, modal_proto.api_pb2.SandboxSnapshotFsResponse]') -> None:
|
415
423
|
pass
|
416
424
|
|
425
|
+
@abc.abstractmethod
|
426
|
+
async def SandboxSnapshotWait(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxSnapshotWaitRequest, modal_proto.api_pb2.SandboxSnapshotWaitResponse]') -> None:
|
427
|
+
pass
|
428
|
+
|
417
429
|
@abc.abstractmethod
|
418
430
|
async def SandboxStdinWrite(self, stream: 'grpclib.server.Stream[modal_proto.api_pb2.SandboxStdinWriteRequest, modal_proto.api_pb2.SandboxStdinWriteResponse]') -> None:
|
419
431
|
pass
|
@@ -1152,12 +1164,30 @@ class ModalClientBase(abc.ABC):
|
|
1152
1164
|
modal_proto.api_pb2.SandboxListRequest,
|
1153
1165
|
modal_proto.api_pb2.SandboxListResponse,
|
1154
1166
|
),
|
1167
|
+
'/modal.client.ModalClient/SandboxRestore': grpclib.const.Handler(
|
1168
|
+
self.SandboxRestore,
|
1169
|
+
grpclib.const.Cardinality.UNARY_UNARY,
|
1170
|
+
modal_proto.api_pb2.SandboxRestoreRequest,
|
1171
|
+
modal_proto.api_pb2.SandboxRestoreResponse,
|
1172
|
+
),
|
1173
|
+
'/modal.client.ModalClient/SandboxSnapshot': grpclib.const.Handler(
|
1174
|
+
self.SandboxSnapshot,
|
1175
|
+
grpclib.const.Cardinality.UNARY_UNARY,
|
1176
|
+
modal_proto.api_pb2.SandboxSnapshotRequest,
|
1177
|
+
modal_proto.api_pb2.SandboxSnapshotResponse,
|
1178
|
+
),
|
1155
1179
|
'/modal.client.ModalClient/SandboxSnapshotFs': grpclib.const.Handler(
|
1156
1180
|
self.SandboxSnapshotFs,
|
1157
1181
|
grpclib.const.Cardinality.UNARY_UNARY,
|
1158
1182
|
modal_proto.api_pb2.SandboxSnapshotFsRequest,
|
1159
1183
|
modal_proto.api_pb2.SandboxSnapshotFsResponse,
|
1160
1184
|
),
|
1185
|
+
'/modal.client.ModalClient/SandboxSnapshotWait': grpclib.const.Handler(
|
1186
|
+
self.SandboxSnapshotWait,
|
1187
|
+
grpclib.const.Cardinality.UNARY_UNARY,
|
1188
|
+
modal_proto.api_pb2.SandboxSnapshotWaitRequest,
|
1189
|
+
modal_proto.api_pb2.SandboxSnapshotWaitResponse,
|
1190
|
+
),
|
1161
1191
|
'/modal.client.ModalClient/SandboxStdinWrite': grpclib.const.Handler(
|
1162
1192
|
self.SandboxStdinWrite,
|
1163
1193
|
grpclib.const.Cardinality.UNARY_UNARY,
|
@@ -1974,12 +2004,30 @@ class ModalClientStub:
|
|
1974
2004
|
modal_proto.api_pb2.SandboxListRequest,
|
1975
2005
|
modal_proto.api_pb2.SandboxListResponse,
|
1976
2006
|
)
|
2007
|
+
self.SandboxRestore = grpclib.client.UnaryUnaryMethod(
|
2008
|
+
channel,
|
2009
|
+
'/modal.client.ModalClient/SandboxRestore',
|
2010
|
+
modal_proto.api_pb2.SandboxRestoreRequest,
|
2011
|
+
modal_proto.api_pb2.SandboxRestoreResponse,
|
2012
|
+
)
|
2013
|
+
self.SandboxSnapshot = grpclib.client.UnaryUnaryMethod(
|
2014
|
+
channel,
|
2015
|
+
'/modal.client.ModalClient/SandboxSnapshot',
|
2016
|
+
modal_proto.api_pb2.SandboxSnapshotRequest,
|
2017
|
+
modal_proto.api_pb2.SandboxSnapshotResponse,
|
2018
|
+
)
|
1977
2019
|
self.SandboxSnapshotFs = grpclib.client.UnaryUnaryMethod(
|
1978
2020
|
channel,
|
1979
2021
|
'/modal.client.ModalClient/SandboxSnapshotFs',
|
1980
2022
|
modal_proto.api_pb2.SandboxSnapshotFsRequest,
|
1981
2023
|
modal_proto.api_pb2.SandboxSnapshotFsResponse,
|
1982
2024
|
)
|
2025
|
+
self.SandboxSnapshotWait = grpclib.client.UnaryUnaryMethod(
|
2026
|
+
channel,
|
2027
|
+
'/modal.client.ModalClient/SandboxSnapshotWait',
|
2028
|
+
modal_proto.api_pb2.SandboxSnapshotWaitRequest,
|
2029
|
+
modal_proto.api_pb2.SandboxSnapshotWaitResponse,
|
2030
|
+
)
|
1983
2031
|
self.SandboxStdinWrite = grpclib.client.UnaryUnaryMethod(
|
1984
2032
|
channel,
|
1985
2033
|
'/modal.client.ModalClient/SandboxStdinWrite',
|