modal 1.1.5.dev83__py3-none-any.whl → 1.3.1.dev8__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/__init__.py +4 -4
- modal/__main__.py +4 -29
- modal/_billing.py +84 -0
- modal/_clustered_functions.py +1 -3
- modal/_container_entrypoint.py +33 -208
- modal/_functions.py +146 -121
- modal/_grpc_client.py +191 -0
- modal/_ipython.py +16 -6
- modal/_load_context.py +106 -0
- modal/_object.py +72 -21
- modal/_output.py +12 -14
- modal/_partial_function.py +31 -4
- modal/_resolver.py +44 -57
- modal/_runtime/container_io_manager.py +26 -28
- modal/_runtime/container_io_manager.pyi +42 -44
- modal/_runtime/gpu_memory_snapshot.py +9 -7
- modal/_runtime/user_code_event_loop.py +80 -0
- modal/_runtime/user_code_imports.py +236 -10
- modal/_serialization.py +2 -1
- modal/_traceback.py +4 -13
- modal/_tunnel.py +16 -11
- modal/_tunnel.pyi +25 -3
- modal/_utils/async_utils.py +337 -10
- modal/_utils/auth_token_manager.py +1 -4
- modal/_utils/blob_utils.py +29 -22
- modal/_utils/function_utils.py +20 -21
- modal/_utils/grpc_testing.py +6 -3
- modal/_utils/grpc_utils.py +223 -64
- modal/_utils/mount_utils.py +26 -1
- modal/_utils/package_utils.py +0 -1
- modal/_utils/rand_pb_testing.py +8 -1
- modal/_utils/task_command_router_client.py +524 -0
- modal/_vendor/cloudpickle.py +144 -48
- modal/app.py +215 -96
- modal/app.pyi +78 -37
- modal/billing.py +5 -0
- modal/builder/2025.06.txt +6 -3
- modal/builder/PREVIEW.txt +2 -1
- modal/builder/base-images.json +4 -2
- modal/cli/_download.py +19 -3
- modal/cli/cluster.py +4 -2
- modal/cli/config.py +3 -1
- modal/cli/container.py +5 -4
- modal/cli/dict.py +5 -2
- modal/cli/entry_point.py +26 -2
- modal/cli/environment.py +2 -16
- modal/cli/launch.py +1 -76
- modal/cli/network_file_system.py +5 -20
- modal/cli/queues.py +5 -4
- modal/cli/run.py +24 -204
- modal/cli/secret.py +1 -2
- modal/cli/shell.py +375 -0
- modal/cli/utils.py +1 -13
- modal/cli/volume.py +11 -17
- modal/client.py +16 -125
- modal/client.pyi +94 -144
- modal/cloud_bucket_mount.py +3 -1
- modal/cloud_bucket_mount.pyi +4 -0
- modal/cls.py +101 -64
- modal/cls.pyi +9 -8
- modal/config.py +21 -1
- modal/container_process.py +288 -12
- modal/container_process.pyi +99 -38
- modal/dict.py +72 -33
- modal/dict.pyi +88 -57
- modal/environments.py +16 -8
- modal/environments.pyi +6 -2
- modal/exception.py +154 -16
- modal/experimental/__init__.py +23 -5
- modal/experimental/flash.py +161 -74
- modal/experimental/flash.pyi +97 -49
- modal/file_io.py +50 -92
- modal/file_io.pyi +117 -89
- modal/functions.pyi +70 -87
- modal/image.py +73 -47
- modal/image.pyi +33 -30
- modal/io_streams.py +500 -149
- modal/io_streams.pyi +279 -189
- modal/mount.py +60 -45
- modal/mount.pyi +41 -17
- modal/network_file_system.py +19 -11
- modal/network_file_system.pyi +72 -39
- modal/object.pyi +114 -22
- modal/parallel_map.py +42 -44
- modal/parallel_map.pyi +9 -17
- modal/partial_function.pyi +4 -2
- modal/proxy.py +14 -6
- modal/proxy.pyi +10 -2
- modal/queue.py +45 -38
- modal/queue.pyi +88 -52
- modal/runner.py +96 -96
- modal/runner.pyi +44 -27
- modal/sandbox.py +225 -108
- modal/sandbox.pyi +226 -63
- modal/secret.py +58 -56
- modal/secret.pyi +28 -13
- modal/serving.py +7 -11
- modal/serving.pyi +7 -8
- modal/snapshot.py +29 -15
- modal/snapshot.pyi +18 -10
- modal/token_flow.py +1 -1
- modal/token_flow.pyi +4 -6
- modal/volume.py +102 -55
- modal/volume.pyi +125 -66
- {modal-1.1.5.dev83.dist-info → modal-1.3.1.dev8.dist-info}/METADATA +10 -9
- modal-1.3.1.dev8.dist-info/RECORD +189 -0
- modal_proto/api.proto +86 -30
- modal_proto/api_grpc.py +10 -25
- modal_proto/api_pb2.py +1080 -1047
- modal_proto/api_pb2.pyi +253 -79
- modal_proto/api_pb2_grpc.py +14 -48
- modal_proto/api_pb2_grpc.pyi +6 -18
- modal_proto/modal_api_grpc.py +175 -176
- modal_proto/{sandbox_router.proto → task_command_router.proto} +62 -45
- modal_proto/task_command_router_grpc.py +138 -0
- modal_proto/task_command_router_pb2.py +180 -0
- modal_proto/{sandbox_router_pb2.pyi → task_command_router_pb2.pyi} +110 -63
- modal_proto/task_command_router_pb2_grpc.py +272 -0
- modal_proto/task_command_router_pb2_grpc.pyi +100 -0
- modal_version/__init__.py +1 -1
- modal_version/__main__.py +1 -1
- modal/cli/programs/launch_instance_ssh.py +0 -94
- modal/cli/programs/run_marimo.py +0 -95
- modal-1.1.5.dev83.dist-info/RECORD +0 -191
- modal_proto/modal_options_grpc.py +0 -3
- modal_proto/options.proto +0 -19
- modal_proto/options_grpc.py +0 -3
- modal_proto/options_pb2.py +0 -35
- modal_proto/options_pb2.pyi +0 -20
- modal_proto/options_pb2_grpc.py +0 -4
- modal_proto/options_pb2_grpc.pyi +0 -7
- modal_proto/sandbox_router_grpc.py +0 -105
- modal_proto/sandbox_router_pb2.py +0 -148
- modal_proto/sandbox_router_pb2_grpc.py +0 -203
- modal_proto/sandbox_router_pb2_grpc.pyi +0 -75
- {modal-1.1.5.dev83.dist-info → modal-1.3.1.dev8.dist-info}/WHEEL +0 -0
- {modal-1.1.5.dev83.dist-info → modal-1.3.1.dev8.dist-info}/entry_points.txt +0 -0
- {modal-1.1.5.dev83.dist-info → modal-1.3.1.dev8.dist-info}/licenses/LICENSE +0 -0
- {modal-1.1.5.dev83.dist-info → modal-1.3.1.dev8.dist-info}/top_level.txt +0 -0
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
# Generated by the Protocol Buffers compiler. DO NOT EDIT!
|
|
2
|
-
# source: modal_proto/sandbox_router.proto
|
|
3
|
-
# plugin: grpclib.plugin.main
|
|
4
|
-
import abc
|
|
5
|
-
import typing
|
|
6
|
-
|
|
7
|
-
import grpclib.const
|
|
8
|
-
import grpclib.client
|
|
9
|
-
if typing.TYPE_CHECKING:
|
|
10
|
-
import grpclib.server
|
|
11
|
-
|
|
12
|
-
import modal_proto.api_pb2
|
|
13
|
-
import modal_proto.sandbox_router_pb2
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
class SandboxRouterBase(abc.ABC):
|
|
17
|
-
|
|
18
|
-
@abc.abstractmethod
|
|
19
|
-
async def SandboxExecPoll(self, stream: 'grpclib.server.Stream[modal_proto.sandbox_router_pb2.SandboxExecPollRequest, modal_proto.sandbox_router_pb2.SandboxExecPollResponse]') -> None:
|
|
20
|
-
pass
|
|
21
|
-
|
|
22
|
-
@abc.abstractmethod
|
|
23
|
-
async def SandboxExecStart(self, stream: 'grpclib.server.Stream[modal_proto.sandbox_router_pb2.SandboxExecStartRequest, modal_proto.sandbox_router_pb2.SandboxExecStartResponse]') -> None:
|
|
24
|
-
pass
|
|
25
|
-
|
|
26
|
-
@abc.abstractmethod
|
|
27
|
-
async def SandboxExecStdinWrite(self, stream: 'grpclib.server.Stream[modal_proto.sandbox_router_pb2.SandboxExecStdinWriteRequest, modal_proto.sandbox_router_pb2.SandboxExecStdinWriteResponse]') -> None:
|
|
28
|
-
pass
|
|
29
|
-
|
|
30
|
-
@abc.abstractmethod
|
|
31
|
-
async def SandboxExecStdioRead(self, stream: 'grpclib.server.Stream[modal_proto.sandbox_router_pb2.SandboxExecStdioReadRequest, modal_proto.sandbox_router_pb2.SandboxExecStdioReadResponse]') -> None:
|
|
32
|
-
pass
|
|
33
|
-
|
|
34
|
-
@abc.abstractmethod
|
|
35
|
-
async def SandboxExecWait(self, stream: 'grpclib.server.Stream[modal_proto.sandbox_router_pb2.SandboxExecWaitRequest, modal_proto.sandbox_router_pb2.SandboxExecWaitResponse]') -> None:
|
|
36
|
-
pass
|
|
37
|
-
|
|
38
|
-
def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
|
|
39
|
-
return {
|
|
40
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecPoll': grpclib.const.Handler(
|
|
41
|
-
self.SandboxExecPoll,
|
|
42
|
-
grpclib.const.Cardinality.UNARY_UNARY,
|
|
43
|
-
modal_proto.sandbox_router_pb2.SandboxExecPollRequest,
|
|
44
|
-
modal_proto.sandbox_router_pb2.SandboxExecPollResponse,
|
|
45
|
-
),
|
|
46
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStart': grpclib.const.Handler(
|
|
47
|
-
self.SandboxExecStart,
|
|
48
|
-
grpclib.const.Cardinality.UNARY_UNARY,
|
|
49
|
-
modal_proto.sandbox_router_pb2.SandboxExecStartRequest,
|
|
50
|
-
modal_proto.sandbox_router_pb2.SandboxExecStartResponse,
|
|
51
|
-
),
|
|
52
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStdinWrite': grpclib.const.Handler(
|
|
53
|
-
self.SandboxExecStdinWrite,
|
|
54
|
-
grpclib.const.Cardinality.UNARY_UNARY,
|
|
55
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdinWriteRequest,
|
|
56
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdinWriteResponse,
|
|
57
|
-
),
|
|
58
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStdioRead': grpclib.const.Handler(
|
|
59
|
-
self.SandboxExecStdioRead,
|
|
60
|
-
grpclib.const.Cardinality.UNARY_STREAM,
|
|
61
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdioReadRequest,
|
|
62
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdioReadResponse,
|
|
63
|
-
),
|
|
64
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecWait': grpclib.const.Handler(
|
|
65
|
-
self.SandboxExecWait,
|
|
66
|
-
grpclib.const.Cardinality.UNARY_UNARY,
|
|
67
|
-
modal_proto.sandbox_router_pb2.SandboxExecWaitRequest,
|
|
68
|
-
modal_proto.sandbox_router_pb2.SandboxExecWaitResponse,
|
|
69
|
-
),
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
class SandboxRouterStub:
|
|
74
|
-
|
|
75
|
-
def __init__(self, channel: grpclib.client.Channel) -> None:
|
|
76
|
-
self.SandboxExecPoll = grpclib.client.UnaryUnaryMethod(
|
|
77
|
-
channel,
|
|
78
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecPoll',
|
|
79
|
-
modal_proto.sandbox_router_pb2.SandboxExecPollRequest,
|
|
80
|
-
modal_proto.sandbox_router_pb2.SandboxExecPollResponse,
|
|
81
|
-
)
|
|
82
|
-
self.SandboxExecStart = grpclib.client.UnaryUnaryMethod(
|
|
83
|
-
channel,
|
|
84
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStart',
|
|
85
|
-
modal_proto.sandbox_router_pb2.SandboxExecStartRequest,
|
|
86
|
-
modal_proto.sandbox_router_pb2.SandboxExecStartResponse,
|
|
87
|
-
)
|
|
88
|
-
self.SandboxExecStdinWrite = grpclib.client.UnaryUnaryMethod(
|
|
89
|
-
channel,
|
|
90
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStdinWrite',
|
|
91
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdinWriteRequest,
|
|
92
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdinWriteResponse,
|
|
93
|
-
)
|
|
94
|
-
self.SandboxExecStdioRead = grpclib.client.UnaryStreamMethod(
|
|
95
|
-
channel,
|
|
96
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStdioRead',
|
|
97
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdioReadRequest,
|
|
98
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdioReadResponse,
|
|
99
|
-
)
|
|
100
|
-
self.SandboxExecWait = grpclib.client.UnaryUnaryMethod(
|
|
101
|
-
channel,
|
|
102
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecWait',
|
|
103
|
-
modal_proto.sandbox_router_pb2.SandboxExecWaitRequest,
|
|
104
|
-
modal_proto.sandbox_router_pb2.SandboxExecWaitResponse,
|
|
105
|
-
)
|
|
@@ -1,148 +0,0 @@
|
|
|
1
|
-
# -*- coding: utf-8 -*-
|
|
2
|
-
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
3
|
-
# source: modal_proto/sandbox_router.proto
|
|
4
|
-
"""Generated protocol buffer code."""
|
|
5
|
-
from google.protobuf.internal import enum_type_wrapper
|
|
6
|
-
from google.protobuf import descriptor as _descriptor
|
|
7
|
-
from google.protobuf import descriptor_pool as _descriptor_pool
|
|
8
|
-
from google.protobuf import message as _message
|
|
9
|
-
from google.protobuf import reflection as _reflection
|
|
10
|
-
from google.protobuf import symbol_database as _symbol_database
|
|
11
|
-
# @@protoc_insertion_point(imports)
|
|
12
|
-
|
|
13
|
-
_sym_db = _symbol_database.Default()
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
from modal_proto import api_pb2 as modal__proto_dot_api__pb2
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n modal_proto/sandbox_router.proto\x12\x14modal.sandbox_router\x1a\x15modal_proto/api.proto\":\n\x16SandboxExecPollRequest\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x0f\n\x07\x65xec_id\x18\x02 \x01(\t\"J\n\x17SandboxExecPollResponse\x12\x0e\n\x04\x63ode\x18\x01 \x01(\x05H\x00\x12\x10\n\x06signal\x18\x02 \x01(\x05H\x00\x42\r\n\x0b\x65xit_status\"\x91\x03\n\x17SandboxExecStartRequest\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x0f\n\x07\x65xec_id\x18\x02 \x01(\t\x12\x14\n\x0c\x63ommand_args\x18\x03 \x03(\t\x12\x44\n\rstdout_config\x18\x04 \x01(\x0e\x32-.modal.sandbox_router.SandboxExecStdoutConfig\x12\x44\n\rstderr_config\x18\x05 \x01(\x0e\x32-.modal.sandbox_router.SandboxExecStderrConfig\x12\x19\n\x0ctimeout_secs\x18\x06 \x01(\rH\x00\x88\x01\x01\x12\x14\n\x07workdir\x18\x07 \x01(\tH\x01\x88\x01\x01\x12\x12\n\nsecret_ids\x18\x08 \x03(\t\x12,\n\x08pty_info\x18\t \x01(\x0b\x32\x15.modal.client.PTYInfoH\x02\x88\x01\x01\x12\x15\n\rruntime_debug\x18\n \x01(\x08\x42\x0f\n\r_timeout_secsB\n\n\x08_workdirB\x0b\n\t_pty_info\"\x1a\n\x18SandboxExecStartResponse\"k\n\x1cSandboxExecStdinWriteRequest\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x0f\n\x07\x65xec_id\x18\x02 \x01(\t\x12\x0e\n\x06offset\x18\x03 \x01(\x04\x12\x0c\n\x04\x64\x61ta\x18\x04 \x01(\x0c\x12\x0b\n\x03\x65of\x18\x05 \x01(\x08\"\x1f\n\x1dSandboxExecStdinWriteResponse\"\x9e\x01\n\x1bSandboxExecStdioReadRequest\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x0f\n\x07\x65xec_id\x18\x02 \x01(\t\x12\x0e\n\x06offset\x18\x03 \x01(\x04\x12M\n\x0f\x66ile_descriptor\x18\x04 \x01(\x0e\x32\x34.modal.sandbox_router.SandboxExecStdioFileDescriptor\",\n\x1cSandboxExecStdioReadResponse\x12\x0c\n\x04\x64\x61ta\x18\x01 \x01(\x0c\":\n\x16SandboxExecWaitRequest\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x0f\n\x07\x65xec_id\x18\x02 \x01(\t\"J\n\x17SandboxExecWaitResponse\x12\x0e\n\x04\x63ode\x18\x01 \x01(\x05H\x00\x12\x10\n\x06signal\x18\x02 \x01(\x05H\x00\x42\r\n\x0b\x65xit_status*\x8d\x01\n\x17SandboxExecStderrConfig\x12&\n\"SANDBOX_EXEC_STDERR_CONFIG_DEVNULL\x10\x00\x12#\n\x1fSANDBOX_EXEC_STDERR_CONFIG_PIPE\x10\x01\x12%\n!SANDBOX_EXEC_STDERR_CONFIG_STDOUT\x10\x02*~\n\x1eSandboxExecStdioFileDescriptor\x12-\n)SANDBOX_EXEC_STDIO_FILE_DESCRIPTOR_STDOUT\x10\x00\x12-\n)SANDBOX_EXEC_STDIO_FILE_DESCRIPTOR_STDERR\x10\x01*f\n\x17SandboxExecStdoutConfig\x12&\n\"SANDBOX_EXEC_STDOUT_CONFIG_DEVNULL\x10\x00\x12#\n\x1fSANDBOX_EXEC_STDOUT_CONFIG_PIPE\x10\x01\x32\xe6\x04\n\rSandboxRouter\x12n\n\x0fSandboxExecPoll\x12,.modal.sandbox_router.SandboxExecPollRequest\x1a-.modal.sandbox_router.SandboxExecPollResponse\x12q\n\x10SandboxExecStart\x12-.modal.sandbox_router.SandboxExecStartRequest\x1a..modal.sandbox_router.SandboxExecStartResponse\x12\x80\x01\n\x15SandboxExecStdinWrite\x12\x32.modal.sandbox_router.SandboxExecStdinWriteRequest\x1a\x33.modal.sandbox_router.SandboxExecStdinWriteResponse\x12\x7f\n\x14SandboxExecStdioRead\x12\x31.modal.sandbox_router.SandboxExecStdioReadRequest\x1a\x32.modal.sandbox_router.SandboxExecStdioReadResponse0\x01\x12n\n\x0fSandboxExecWait\x12,.modal.sandbox_router.SandboxExecWaitRequest\x1a-.modal.sandbox_router.SandboxExecWaitResponseb\x06proto3')
|
|
20
|
-
|
|
21
|
-
_SANDBOXEXECSTDERRCONFIG = DESCRIPTOR.enum_types_by_name['SandboxExecStderrConfig']
|
|
22
|
-
SandboxExecStderrConfig = enum_type_wrapper.EnumTypeWrapper(_SANDBOXEXECSTDERRCONFIG)
|
|
23
|
-
_SANDBOXEXECSTDIOFILEDESCRIPTOR = DESCRIPTOR.enum_types_by_name['SandboxExecStdioFileDescriptor']
|
|
24
|
-
SandboxExecStdioFileDescriptor = enum_type_wrapper.EnumTypeWrapper(_SANDBOXEXECSTDIOFILEDESCRIPTOR)
|
|
25
|
-
_SANDBOXEXECSTDOUTCONFIG = DESCRIPTOR.enum_types_by_name['SandboxExecStdoutConfig']
|
|
26
|
-
SandboxExecStdoutConfig = enum_type_wrapper.EnumTypeWrapper(_SANDBOXEXECSTDOUTCONFIG)
|
|
27
|
-
SANDBOX_EXEC_STDERR_CONFIG_DEVNULL = 0
|
|
28
|
-
SANDBOX_EXEC_STDERR_CONFIG_PIPE = 1
|
|
29
|
-
SANDBOX_EXEC_STDERR_CONFIG_STDOUT = 2
|
|
30
|
-
SANDBOX_EXEC_STDIO_FILE_DESCRIPTOR_STDOUT = 0
|
|
31
|
-
SANDBOX_EXEC_STDIO_FILE_DESCRIPTOR_STDERR = 1
|
|
32
|
-
SANDBOX_EXEC_STDOUT_CONFIG_DEVNULL = 0
|
|
33
|
-
SANDBOX_EXEC_STDOUT_CONFIG_PIPE = 1
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
_SANDBOXEXECPOLLREQUEST = DESCRIPTOR.message_types_by_name['SandboxExecPollRequest']
|
|
37
|
-
_SANDBOXEXECPOLLRESPONSE = DESCRIPTOR.message_types_by_name['SandboxExecPollResponse']
|
|
38
|
-
_SANDBOXEXECSTARTREQUEST = DESCRIPTOR.message_types_by_name['SandboxExecStartRequest']
|
|
39
|
-
_SANDBOXEXECSTARTRESPONSE = DESCRIPTOR.message_types_by_name['SandboxExecStartResponse']
|
|
40
|
-
_SANDBOXEXECSTDINWRITEREQUEST = DESCRIPTOR.message_types_by_name['SandboxExecStdinWriteRequest']
|
|
41
|
-
_SANDBOXEXECSTDINWRITERESPONSE = DESCRIPTOR.message_types_by_name['SandboxExecStdinWriteResponse']
|
|
42
|
-
_SANDBOXEXECSTDIOREADREQUEST = DESCRIPTOR.message_types_by_name['SandboxExecStdioReadRequest']
|
|
43
|
-
_SANDBOXEXECSTDIOREADRESPONSE = DESCRIPTOR.message_types_by_name['SandboxExecStdioReadResponse']
|
|
44
|
-
_SANDBOXEXECWAITREQUEST = DESCRIPTOR.message_types_by_name['SandboxExecWaitRequest']
|
|
45
|
-
_SANDBOXEXECWAITRESPONSE = DESCRIPTOR.message_types_by_name['SandboxExecWaitResponse']
|
|
46
|
-
SandboxExecPollRequest = _reflection.GeneratedProtocolMessageType('SandboxExecPollRequest', (_message.Message,), {
|
|
47
|
-
'DESCRIPTOR' : _SANDBOXEXECPOLLREQUEST,
|
|
48
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
49
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecPollRequest)
|
|
50
|
-
})
|
|
51
|
-
_sym_db.RegisterMessage(SandboxExecPollRequest)
|
|
52
|
-
|
|
53
|
-
SandboxExecPollResponse = _reflection.GeneratedProtocolMessageType('SandboxExecPollResponse', (_message.Message,), {
|
|
54
|
-
'DESCRIPTOR' : _SANDBOXEXECPOLLRESPONSE,
|
|
55
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
56
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecPollResponse)
|
|
57
|
-
})
|
|
58
|
-
_sym_db.RegisterMessage(SandboxExecPollResponse)
|
|
59
|
-
|
|
60
|
-
SandboxExecStartRequest = _reflection.GeneratedProtocolMessageType('SandboxExecStartRequest', (_message.Message,), {
|
|
61
|
-
'DESCRIPTOR' : _SANDBOXEXECSTARTREQUEST,
|
|
62
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
63
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecStartRequest)
|
|
64
|
-
})
|
|
65
|
-
_sym_db.RegisterMessage(SandboxExecStartRequest)
|
|
66
|
-
|
|
67
|
-
SandboxExecStartResponse = _reflection.GeneratedProtocolMessageType('SandboxExecStartResponse', (_message.Message,), {
|
|
68
|
-
'DESCRIPTOR' : _SANDBOXEXECSTARTRESPONSE,
|
|
69
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
70
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecStartResponse)
|
|
71
|
-
})
|
|
72
|
-
_sym_db.RegisterMessage(SandboxExecStartResponse)
|
|
73
|
-
|
|
74
|
-
SandboxExecStdinWriteRequest = _reflection.GeneratedProtocolMessageType('SandboxExecStdinWriteRequest', (_message.Message,), {
|
|
75
|
-
'DESCRIPTOR' : _SANDBOXEXECSTDINWRITEREQUEST,
|
|
76
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
77
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecStdinWriteRequest)
|
|
78
|
-
})
|
|
79
|
-
_sym_db.RegisterMessage(SandboxExecStdinWriteRequest)
|
|
80
|
-
|
|
81
|
-
SandboxExecStdinWriteResponse = _reflection.GeneratedProtocolMessageType('SandboxExecStdinWriteResponse', (_message.Message,), {
|
|
82
|
-
'DESCRIPTOR' : _SANDBOXEXECSTDINWRITERESPONSE,
|
|
83
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
84
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecStdinWriteResponse)
|
|
85
|
-
})
|
|
86
|
-
_sym_db.RegisterMessage(SandboxExecStdinWriteResponse)
|
|
87
|
-
|
|
88
|
-
SandboxExecStdioReadRequest = _reflection.GeneratedProtocolMessageType('SandboxExecStdioReadRequest', (_message.Message,), {
|
|
89
|
-
'DESCRIPTOR' : _SANDBOXEXECSTDIOREADREQUEST,
|
|
90
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
91
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecStdioReadRequest)
|
|
92
|
-
})
|
|
93
|
-
_sym_db.RegisterMessage(SandboxExecStdioReadRequest)
|
|
94
|
-
|
|
95
|
-
SandboxExecStdioReadResponse = _reflection.GeneratedProtocolMessageType('SandboxExecStdioReadResponse', (_message.Message,), {
|
|
96
|
-
'DESCRIPTOR' : _SANDBOXEXECSTDIOREADRESPONSE,
|
|
97
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
98
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecStdioReadResponse)
|
|
99
|
-
})
|
|
100
|
-
_sym_db.RegisterMessage(SandboxExecStdioReadResponse)
|
|
101
|
-
|
|
102
|
-
SandboxExecWaitRequest = _reflection.GeneratedProtocolMessageType('SandboxExecWaitRequest', (_message.Message,), {
|
|
103
|
-
'DESCRIPTOR' : _SANDBOXEXECWAITREQUEST,
|
|
104
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
105
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecWaitRequest)
|
|
106
|
-
})
|
|
107
|
-
_sym_db.RegisterMessage(SandboxExecWaitRequest)
|
|
108
|
-
|
|
109
|
-
SandboxExecWaitResponse = _reflection.GeneratedProtocolMessageType('SandboxExecWaitResponse', (_message.Message,), {
|
|
110
|
-
'DESCRIPTOR' : _SANDBOXEXECWAITRESPONSE,
|
|
111
|
-
'__module__' : 'modal_proto.sandbox_router_pb2'
|
|
112
|
-
# @@protoc_insertion_point(class_scope:modal.sandbox_router.SandboxExecWaitResponse)
|
|
113
|
-
})
|
|
114
|
-
_sym_db.RegisterMessage(SandboxExecWaitResponse)
|
|
115
|
-
|
|
116
|
-
_SANDBOXROUTER = DESCRIPTOR.services_by_name['SandboxRouter']
|
|
117
|
-
if _descriptor._USE_C_DESCRIPTORS == False:
|
|
118
|
-
|
|
119
|
-
DESCRIPTOR._options = None
|
|
120
|
-
_SANDBOXEXECSTDERRCONFIG._serialized_start=1135
|
|
121
|
-
_SANDBOXEXECSTDERRCONFIG._serialized_end=1276
|
|
122
|
-
_SANDBOXEXECSTDIOFILEDESCRIPTOR._serialized_start=1278
|
|
123
|
-
_SANDBOXEXECSTDIOFILEDESCRIPTOR._serialized_end=1404
|
|
124
|
-
_SANDBOXEXECSTDOUTCONFIG._serialized_start=1406
|
|
125
|
-
_SANDBOXEXECSTDOUTCONFIG._serialized_end=1508
|
|
126
|
-
_SANDBOXEXECPOLLREQUEST._serialized_start=81
|
|
127
|
-
_SANDBOXEXECPOLLREQUEST._serialized_end=139
|
|
128
|
-
_SANDBOXEXECPOLLRESPONSE._serialized_start=141
|
|
129
|
-
_SANDBOXEXECPOLLRESPONSE._serialized_end=215
|
|
130
|
-
_SANDBOXEXECSTARTREQUEST._serialized_start=218
|
|
131
|
-
_SANDBOXEXECSTARTREQUEST._serialized_end=619
|
|
132
|
-
_SANDBOXEXECSTARTRESPONSE._serialized_start=621
|
|
133
|
-
_SANDBOXEXECSTARTRESPONSE._serialized_end=647
|
|
134
|
-
_SANDBOXEXECSTDINWRITEREQUEST._serialized_start=649
|
|
135
|
-
_SANDBOXEXECSTDINWRITEREQUEST._serialized_end=756
|
|
136
|
-
_SANDBOXEXECSTDINWRITERESPONSE._serialized_start=758
|
|
137
|
-
_SANDBOXEXECSTDINWRITERESPONSE._serialized_end=789
|
|
138
|
-
_SANDBOXEXECSTDIOREADREQUEST._serialized_start=792
|
|
139
|
-
_SANDBOXEXECSTDIOREADREQUEST._serialized_end=950
|
|
140
|
-
_SANDBOXEXECSTDIOREADRESPONSE._serialized_start=952
|
|
141
|
-
_SANDBOXEXECSTDIOREADRESPONSE._serialized_end=996
|
|
142
|
-
_SANDBOXEXECWAITREQUEST._serialized_start=998
|
|
143
|
-
_SANDBOXEXECWAITREQUEST._serialized_end=1056
|
|
144
|
-
_SANDBOXEXECWAITRESPONSE._serialized_start=1058
|
|
145
|
-
_SANDBOXEXECWAITRESPONSE._serialized_end=1132
|
|
146
|
-
_SANDBOXROUTER._serialized_start=1511
|
|
147
|
-
_SANDBOXROUTER._serialized_end=2125
|
|
148
|
-
# @@protoc_insertion_point(module_scope)
|
|
@@ -1,203 +0,0 @@
|
|
|
1
|
-
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
|
|
2
|
-
"""Client and server classes corresponding to protobuf-defined services."""
|
|
3
|
-
import grpc
|
|
4
|
-
|
|
5
|
-
from modal_proto import sandbox_router_pb2 as modal__proto_dot_sandbox__router__pb2
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
class SandboxRouterStub(object):
|
|
9
|
-
"""Missing associated documentation comment in .proto file."""
|
|
10
|
-
|
|
11
|
-
def __init__(self, channel):
|
|
12
|
-
"""Constructor.
|
|
13
|
-
|
|
14
|
-
Args:
|
|
15
|
-
channel: A grpc.Channel.
|
|
16
|
-
"""
|
|
17
|
-
self.SandboxExecPoll = channel.unary_unary(
|
|
18
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecPoll',
|
|
19
|
-
request_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecPollRequest.SerializeToString,
|
|
20
|
-
response_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecPollResponse.FromString,
|
|
21
|
-
)
|
|
22
|
-
self.SandboxExecStart = channel.unary_unary(
|
|
23
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStart',
|
|
24
|
-
request_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStartRequest.SerializeToString,
|
|
25
|
-
response_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStartResponse.FromString,
|
|
26
|
-
)
|
|
27
|
-
self.SandboxExecStdinWrite = channel.unary_unary(
|
|
28
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStdinWrite',
|
|
29
|
-
request_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdinWriteRequest.SerializeToString,
|
|
30
|
-
response_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdinWriteResponse.FromString,
|
|
31
|
-
)
|
|
32
|
-
self.SandboxExecStdioRead = channel.unary_stream(
|
|
33
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecStdioRead',
|
|
34
|
-
request_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdioReadRequest.SerializeToString,
|
|
35
|
-
response_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdioReadResponse.FromString,
|
|
36
|
-
)
|
|
37
|
-
self.SandboxExecWait = channel.unary_unary(
|
|
38
|
-
'/modal.sandbox_router.SandboxRouter/SandboxExecWait',
|
|
39
|
-
request_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecWaitRequest.SerializeToString,
|
|
40
|
-
response_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecWaitResponse.FromString,
|
|
41
|
-
)
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
class SandboxRouterServicer(object):
|
|
45
|
-
"""Missing associated documentation comment in .proto file."""
|
|
46
|
-
|
|
47
|
-
def SandboxExecPoll(self, request, context):
|
|
48
|
-
"""Poll for the exit status of an exec'd command.
|
|
49
|
-
"""
|
|
50
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
51
|
-
context.set_details('Method not implemented!')
|
|
52
|
-
raise NotImplementedError('Method not implemented!')
|
|
53
|
-
|
|
54
|
-
def SandboxExecStart(self, request, context):
|
|
55
|
-
"""Execute a command in the sandbox.
|
|
56
|
-
"""
|
|
57
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
58
|
-
context.set_details('Method not implemented!')
|
|
59
|
-
raise NotImplementedError('Method not implemented!')
|
|
60
|
-
|
|
61
|
-
def SandboxExecStdinWrite(self, request, context):
|
|
62
|
-
"""Write to the stdin stream of an exec'd command.
|
|
63
|
-
"""
|
|
64
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
65
|
-
context.set_details('Method not implemented!')
|
|
66
|
-
raise NotImplementedError('Method not implemented!')
|
|
67
|
-
|
|
68
|
-
def SandboxExecStdioRead(self, request, context):
|
|
69
|
-
"""Get a stream of output from the stdout or stderr stream of an exec'd command.
|
|
70
|
-
"""
|
|
71
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
72
|
-
context.set_details('Method not implemented!')
|
|
73
|
-
raise NotImplementedError('Method not implemented!')
|
|
74
|
-
|
|
75
|
-
def SandboxExecWait(self, request, context):
|
|
76
|
-
"""Wait for an exec'd command to exit and return the exit code.
|
|
77
|
-
"""
|
|
78
|
-
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
|
79
|
-
context.set_details('Method not implemented!')
|
|
80
|
-
raise NotImplementedError('Method not implemented!')
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
def add_SandboxRouterServicer_to_server(servicer, server):
|
|
84
|
-
rpc_method_handlers = {
|
|
85
|
-
'SandboxExecPoll': grpc.unary_unary_rpc_method_handler(
|
|
86
|
-
servicer.SandboxExecPoll,
|
|
87
|
-
request_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecPollRequest.FromString,
|
|
88
|
-
response_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecPollResponse.SerializeToString,
|
|
89
|
-
),
|
|
90
|
-
'SandboxExecStart': grpc.unary_unary_rpc_method_handler(
|
|
91
|
-
servicer.SandboxExecStart,
|
|
92
|
-
request_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStartRequest.FromString,
|
|
93
|
-
response_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStartResponse.SerializeToString,
|
|
94
|
-
),
|
|
95
|
-
'SandboxExecStdinWrite': grpc.unary_unary_rpc_method_handler(
|
|
96
|
-
servicer.SandboxExecStdinWrite,
|
|
97
|
-
request_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdinWriteRequest.FromString,
|
|
98
|
-
response_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdinWriteResponse.SerializeToString,
|
|
99
|
-
),
|
|
100
|
-
'SandboxExecStdioRead': grpc.unary_stream_rpc_method_handler(
|
|
101
|
-
servicer.SandboxExecStdioRead,
|
|
102
|
-
request_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdioReadRequest.FromString,
|
|
103
|
-
response_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecStdioReadResponse.SerializeToString,
|
|
104
|
-
),
|
|
105
|
-
'SandboxExecWait': grpc.unary_unary_rpc_method_handler(
|
|
106
|
-
servicer.SandboxExecWait,
|
|
107
|
-
request_deserializer=modal__proto_dot_sandbox__router__pb2.SandboxExecWaitRequest.FromString,
|
|
108
|
-
response_serializer=modal__proto_dot_sandbox__router__pb2.SandboxExecWaitResponse.SerializeToString,
|
|
109
|
-
),
|
|
110
|
-
}
|
|
111
|
-
generic_handler = grpc.method_handlers_generic_handler(
|
|
112
|
-
'modal.sandbox_router.SandboxRouter', rpc_method_handlers)
|
|
113
|
-
server.add_generic_rpc_handlers((generic_handler,))
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
# This class is part of an EXPERIMENTAL API.
|
|
117
|
-
class SandboxRouter(object):
|
|
118
|
-
"""Missing associated documentation comment in .proto file."""
|
|
119
|
-
|
|
120
|
-
@staticmethod
|
|
121
|
-
def SandboxExecPoll(request,
|
|
122
|
-
target,
|
|
123
|
-
options=(),
|
|
124
|
-
channel_credentials=None,
|
|
125
|
-
call_credentials=None,
|
|
126
|
-
insecure=False,
|
|
127
|
-
compression=None,
|
|
128
|
-
wait_for_ready=None,
|
|
129
|
-
timeout=None,
|
|
130
|
-
metadata=None):
|
|
131
|
-
return grpc.experimental.unary_unary(request, target, '/modal.sandbox_router.SandboxRouter/SandboxExecPoll',
|
|
132
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecPollRequest.SerializeToString,
|
|
133
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecPollResponse.FromString,
|
|
134
|
-
options, channel_credentials,
|
|
135
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
136
|
-
|
|
137
|
-
@staticmethod
|
|
138
|
-
def SandboxExecStart(request,
|
|
139
|
-
target,
|
|
140
|
-
options=(),
|
|
141
|
-
channel_credentials=None,
|
|
142
|
-
call_credentials=None,
|
|
143
|
-
insecure=False,
|
|
144
|
-
compression=None,
|
|
145
|
-
wait_for_ready=None,
|
|
146
|
-
timeout=None,
|
|
147
|
-
metadata=None):
|
|
148
|
-
return grpc.experimental.unary_unary(request, target, '/modal.sandbox_router.SandboxRouter/SandboxExecStart',
|
|
149
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecStartRequest.SerializeToString,
|
|
150
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecStartResponse.FromString,
|
|
151
|
-
options, channel_credentials,
|
|
152
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
153
|
-
|
|
154
|
-
@staticmethod
|
|
155
|
-
def SandboxExecStdinWrite(request,
|
|
156
|
-
target,
|
|
157
|
-
options=(),
|
|
158
|
-
channel_credentials=None,
|
|
159
|
-
call_credentials=None,
|
|
160
|
-
insecure=False,
|
|
161
|
-
compression=None,
|
|
162
|
-
wait_for_ready=None,
|
|
163
|
-
timeout=None,
|
|
164
|
-
metadata=None):
|
|
165
|
-
return grpc.experimental.unary_unary(request, target, '/modal.sandbox_router.SandboxRouter/SandboxExecStdinWrite',
|
|
166
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecStdinWriteRequest.SerializeToString,
|
|
167
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecStdinWriteResponse.FromString,
|
|
168
|
-
options, channel_credentials,
|
|
169
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
170
|
-
|
|
171
|
-
@staticmethod
|
|
172
|
-
def SandboxExecStdioRead(request,
|
|
173
|
-
target,
|
|
174
|
-
options=(),
|
|
175
|
-
channel_credentials=None,
|
|
176
|
-
call_credentials=None,
|
|
177
|
-
insecure=False,
|
|
178
|
-
compression=None,
|
|
179
|
-
wait_for_ready=None,
|
|
180
|
-
timeout=None,
|
|
181
|
-
metadata=None):
|
|
182
|
-
return grpc.experimental.unary_stream(request, target, '/modal.sandbox_router.SandboxRouter/SandboxExecStdioRead',
|
|
183
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecStdioReadRequest.SerializeToString,
|
|
184
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecStdioReadResponse.FromString,
|
|
185
|
-
options, channel_credentials,
|
|
186
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
187
|
-
|
|
188
|
-
@staticmethod
|
|
189
|
-
def SandboxExecWait(request,
|
|
190
|
-
target,
|
|
191
|
-
options=(),
|
|
192
|
-
channel_credentials=None,
|
|
193
|
-
call_credentials=None,
|
|
194
|
-
insecure=False,
|
|
195
|
-
compression=None,
|
|
196
|
-
wait_for_ready=None,
|
|
197
|
-
timeout=None,
|
|
198
|
-
metadata=None):
|
|
199
|
-
return grpc.experimental.unary_unary(request, target, '/modal.sandbox_router.SandboxRouter/SandboxExecWait',
|
|
200
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecWaitRequest.SerializeToString,
|
|
201
|
-
modal__proto_dot_sandbox__router__pb2.SandboxExecWaitResponse.FromString,
|
|
202
|
-
options, channel_credentials,
|
|
203
|
-
insecure, call_credentials, compression, wait_for_ready, timeout, metadata)
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
"""
|
|
2
|
-
@generated by mypy-protobuf. Do not edit manually!
|
|
3
|
-
isort:skip_file
|
|
4
|
-
"""
|
|
5
|
-
import abc
|
|
6
|
-
import collections.abc
|
|
7
|
-
import grpc
|
|
8
|
-
import modal_proto.sandbox_router_pb2
|
|
9
|
-
|
|
10
|
-
class SandboxRouterStub:
|
|
11
|
-
def __init__(self, channel: grpc.Channel) -> None: ...
|
|
12
|
-
SandboxExecPoll: grpc.UnaryUnaryMultiCallable[
|
|
13
|
-
modal_proto.sandbox_router_pb2.SandboxExecPollRequest,
|
|
14
|
-
modal_proto.sandbox_router_pb2.SandboxExecPollResponse,
|
|
15
|
-
]
|
|
16
|
-
"""Poll for the exit status of an exec'd command."""
|
|
17
|
-
SandboxExecStart: grpc.UnaryUnaryMultiCallable[
|
|
18
|
-
modal_proto.sandbox_router_pb2.SandboxExecStartRequest,
|
|
19
|
-
modal_proto.sandbox_router_pb2.SandboxExecStartResponse,
|
|
20
|
-
]
|
|
21
|
-
"""Execute a command in the sandbox."""
|
|
22
|
-
SandboxExecStdinWrite: grpc.UnaryUnaryMultiCallable[
|
|
23
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdinWriteRequest,
|
|
24
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdinWriteResponse,
|
|
25
|
-
]
|
|
26
|
-
"""Write to the stdin stream of an exec'd command."""
|
|
27
|
-
SandboxExecStdioRead: grpc.UnaryStreamMultiCallable[
|
|
28
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdioReadRequest,
|
|
29
|
-
modal_proto.sandbox_router_pb2.SandboxExecStdioReadResponse,
|
|
30
|
-
]
|
|
31
|
-
"""Get a stream of output from the stdout or stderr stream of an exec'd command."""
|
|
32
|
-
SandboxExecWait: grpc.UnaryUnaryMultiCallable[
|
|
33
|
-
modal_proto.sandbox_router_pb2.SandboxExecWaitRequest,
|
|
34
|
-
modal_proto.sandbox_router_pb2.SandboxExecWaitResponse,
|
|
35
|
-
]
|
|
36
|
-
"""Wait for an exec'd command to exit and return the exit code."""
|
|
37
|
-
|
|
38
|
-
class SandboxRouterServicer(metaclass=abc.ABCMeta):
|
|
39
|
-
@abc.abstractmethod
|
|
40
|
-
def SandboxExecPoll(
|
|
41
|
-
self,
|
|
42
|
-
request: modal_proto.sandbox_router_pb2.SandboxExecPollRequest,
|
|
43
|
-
context: grpc.ServicerContext,
|
|
44
|
-
) -> modal_proto.sandbox_router_pb2.SandboxExecPollResponse:
|
|
45
|
-
"""Poll for the exit status of an exec'd command."""
|
|
46
|
-
@abc.abstractmethod
|
|
47
|
-
def SandboxExecStart(
|
|
48
|
-
self,
|
|
49
|
-
request: modal_proto.sandbox_router_pb2.SandboxExecStartRequest,
|
|
50
|
-
context: grpc.ServicerContext,
|
|
51
|
-
) -> modal_proto.sandbox_router_pb2.SandboxExecStartResponse:
|
|
52
|
-
"""Execute a command in the sandbox."""
|
|
53
|
-
@abc.abstractmethod
|
|
54
|
-
def SandboxExecStdinWrite(
|
|
55
|
-
self,
|
|
56
|
-
request: modal_proto.sandbox_router_pb2.SandboxExecStdinWriteRequest,
|
|
57
|
-
context: grpc.ServicerContext,
|
|
58
|
-
) -> modal_proto.sandbox_router_pb2.SandboxExecStdinWriteResponse:
|
|
59
|
-
"""Write to the stdin stream of an exec'd command."""
|
|
60
|
-
@abc.abstractmethod
|
|
61
|
-
def SandboxExecStdioRead(
|
|
62
|
-
self,
|
|
63
|
-
request: modal_proto.sandbox_router_pb2.SandboxExecStdioReadRequest,
|
|
64
|
-
context: grpc.ServicerContext,
|
|
65
|
-
) -> collections.abc.Iterator[modal_proto.sandbox_router_pb2.SandboxExecStdioReadResponse]:
|
|
66
|
-
"""Get a stream of output from the stdout or stderr stream of an exec'd command."""
|
|
67
|
-
@abc.abstractmethod
|
|
68
|
-
def SandboxExecWait(
|
|
69
|
-
self,
|
|
70
|
-
request: modal_proto.sandbox_router_pb2.SandboxExecWaitRequest,
|
|
71
|
-
context: grpc.ServicerContext,
|
|
72
|
-
) -> modal_proto.sandbox_router_pb2.SandboxExecWaitResponse:
|
|
73
|
-
"""Wait for an exec'd command to exit and return the exit code."""
|
|
74
|
-
|
|
75
|
-
def add_SandboxRouterServicer_to_server(servicer: SandboxRouterServicer, server: grpc.Server) -> None: ...
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|