modal 1.2.2.dev6__tar.gz → 1.2.2.dev7__tar.gz
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-1.2.2.dev6 → modal-1.2.2.dev7}/PKG-INFO +1 -1
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/client.pyi +2 -2
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/functions.pyi +6 -6
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/io_streams.py +7 -39
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/io_streams.pyi +15 -91
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/sandbox.py +2 -7
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal.egg-info/PKG-INFO +1 -1
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_version/__init__.py +1 -1
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/LICENSE +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/README.md +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/__main__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_billing.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_clustered_functions.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_clustered_functions.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_container_entrypoint.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_functions.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_ipython.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_location.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_object.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_output.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_partial_function.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_pty.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_resolver.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_resources.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/asgi.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/container_io_manager.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/container_io_manager.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/execution_context.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/execution_context.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/gpu_memory_snapshot.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/telemetry.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_runtime/user_code_imports.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_serialization.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_traceback.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_tunnel.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_tunnel.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_type_manager.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/app_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/async_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/auth_token_manager.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/blob_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/bytes_io_segment_payload.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/deprecation.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/docker_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/function_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/git_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/grpc_testing.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/grpc_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/hash_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/http_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/jwt_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/logger.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/mount_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/name_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/package_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/pattern_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/rand_pb_testing.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/shell_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/task_command_router_client.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_utils/time_utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_vendor/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_vendor/a2wsgi_wsgi.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_vendor/cloudpickle.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_vendor/tblib.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/_watcher.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/app.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/app.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/billing.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/2023.12.312.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/2023.12.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/2024.04.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/2024.10.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/2025.06.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/PREVIEW.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/README.md +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/builder/base-images.json +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/call_graph.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/_download.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/_traceback.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/app.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/cluster.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/config.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/container.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/dict.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/entry_point.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/environment.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/import_refs.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/launch.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/network_file_system.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/profile.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/programs/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/programs/launch_instance_ssh.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/programs/run_jupyter.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/programs/run_marimo.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/programs/vscode.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/queues.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/run.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/secret.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/token.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/utils.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cli/volume.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/client.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cloud_bucket_mount.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cloud_bucket_mount.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cls.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/cls.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/config.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/container_process.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/container_process.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/dict.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/dict.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/environments.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/environments.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/exception.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/experimental/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/experimental/flash.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/experimental/flash.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/experimental/ipython.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/file_io.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/file_io.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/file_pattern_matcher.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/functions.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/gpu.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/image.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/image.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/mount.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/mount.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/network_file_system.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/network_file_system.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/object.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/object.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/output.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/parallel_map.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/parallel_map.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/partial_function.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/partial_function.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/proxy.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/proxy.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/py.typed +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/queue.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/queue.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/retries.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/runner.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/runner.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/running_app.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/sandbox.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/schedule.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/scheduler_placement.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/secret.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/secret.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/serving.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/serving.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/snapshot.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/snapshot.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/stream_type.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/token_flow.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/token_flow.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/volume.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal/volume.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal.egg-info/SOURCES.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal.egg-info/dependency_links.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal.egg-info/entry_points.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal.egg-info/requires.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal.egg-info/top_level.txt +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_docs/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_docs/gen_cli_docs.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_docs/gen_reference_docs.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_docs/mdmd/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_docs/mdmd/mdmd.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_docs/mdmd/signatures.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/__init__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/api.proto +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/api_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/api_pb2.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/api_pb2.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/api_pb2_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/api_pb2_grpc.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/modal_api_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/py.typed +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/sandbox_router.proto +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/sandbox_router_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/sandbox_router_pb2.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/sandbox_router_pb2.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/sandbox_router_pb2_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/sandbox_router_pb2_grpc.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/task_command_router.proto +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/task_command_router_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/task_command_router_pb2.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/task_command_router_pb2.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/task_command_router_pb2_grpc.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_proto/task_command_router_pb2_grpc.pyi +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/modal_version/__main__.py +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/pyproject.toml +0 -0
- {modal-1.2.2.dev6 → modal-1.2.2.dev7}/setup.cfg +0 -0
|
@@ -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.2.2.
|
|
36
|
+
version: str = "1.2.2.dev7",
|
|
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.2.2.
|
|
167
|
+
version: str = "1.2.2.dev7",
|
|
168
168
|
):
|
|
169
169
|
"""mdmd:hidden
|
|
170
170
|
The Modal client object is not intended to be instantiated directly by users.
|
|
@@ -401,7 +401,7 @@ class Function(
|
|
|
401
401
|
|
|
402
402
|
_call_generator: ___call_generator_spec[typing_extensions.Self]
|
|
403
403
|
|
|
404
|
-
class __remote_spec(typing_extensions.Protocol[
|
|
404
|
+
class __remote_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER, SUPERSELF]):
|
|
405
405
|
def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> ReturnType_INNER:
|
|
406
406
|
"""Calls the function remotely, executing it with the given arguments and returning the execution's result."""
|
|
407
407
|
...
|
|
@@ -410,7 +410,7 @@ class Function(
|
|
|
410
410
|
"""Calls the function remotely, executing it with the given arguments and returning the execution's result."""
|
|
411
411
|
...
|
|
412
412
|
|
|
413
|
-
remote: __remote_spec[modal._functions.
|
|
413
|
+
remote: __remote_spec[modal._functions.ReturnType, modal._functions.P, typing_extensions.Self]
|
|
414
414
|
|
|
415
415
|
class __remote_gen_spec(typing_extensions.Protocol[SUPERSELF]):
|
|
416
416
|
def __call__(self, /, *args, **kwargs) -> typing.Generator[typing.Any, None, None]:
|
|
@@ -437,7 +437,7 @@ class Function(
|
|
|
437
437
|
"""
|
|
438
438
|
...
|
|
439
439
|
|
|
440
|
-
class ___experimental_spawn_spec(typing_extensions.Protocol[
|
|
440
|
+
class ___experimental_spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER, SUPERSELF]):
|
|
441
441
|
def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]:
|
|
442
442
|
"""[Experimental] Calls the function with the given arguments, without waiting for the results.
|
|
443
443
|
|
|
@@ -461,7 +461,7 @@ class Function(
|
|
|
461
461
|
...
|
|
462
462
|
|
|
463
463
|
_experimental_spawn: ___experimental_spawn_spec[
|
|
464
|
-
modal._functions.
|
|
464
|
+
modal._functions.ReturnType, modal._functions.P, typing_extensions.Self
|
|
465
465
|
]
|
|
466
466
|
|
|
467
467
|
class ___spawn_map_inner_spec(typing_extensions.Protocol[P_INNER, SUPERSELF]):
|
|
@@ -470,7 +470,7 @@ class Function(
|
|
|
470
470
|
|
|
471
471
|
_spawn_map_inner: ___spawn_map_inner_spec[modal._functions.P, typing_extensions.Self]
|
|
472
472
|
|
|
473
|
-
class __spawn_spec(typing_extensions.Protocol[
|
|
473
|
+
class __spawn_spec(typing_extensions.Protocol[ReturnType_INNER, P_INNER, SUPERSELF]):
|
|
474
474
|
def __call__(self, /, *args: P_INNER.args, **kwargs: P_INNER.kwargs) -> FunctionCall[ReturnType_INNER]:
|
|
475
475
|
"""Calls the function with the given arguments, without waiting for the results.
|
|
476
476
|
|
|
@@ -491,7 +491,7 @@ class Function(
|
|
|
491
491
|
"""
|
|
492
492
|
...
|
|
493
493
|
|
|
494
|
-
spawn: __spawn_spec[modal._functions.
|
|
494
|
+
spawn: __spawn_spec[modal._functions.ReturnType, modal._functions.P, typing_extensions.Self]
|
|
495
495
|
|
|
496
496
|
def get_raw_f(self) -> collections.abc.Callable[..., typing.Any]:
|
|
497
497
|
"""Return the inner Python object wrapped by this Modal Function."""
|
|
@@ -492,21 +492,6 @@ class _StreamReader(Generic[T]):
|
|
|
492
492
|
|
|
493
493
|
As an asynchronous iterable, the object supports the `for` and `async for`
|
|
494
494
|
statements. Just loop over the object to read in chunks.
|
|
495
|
-
|
|
496
|
-
**Usage**
|
|
497
|
-
|
|
498
|
-
```python fixture:running_app
|
|
499
|
-
from modal import Sandbox
|
|
500
|
-
|
|
501
|
-
sandbox = Sandbox.create(
|
|
502
|
-
"bash",
|
|
503
|
-
"-c",
|
|
504
|
-
"for i in $(seq 1 10); do echo foo; sleep 0.1; done",
|
|
505
|
-
app=running_app,
|
|
506
|
-
)
|
|
507
|
-
for message in sandbox.stdout:
|
|
508
|
-
print(f"Message: {message}")
|
|
509
|
-
```
|
|
510
495
|
"""
|
|
511
496
|
|
|
512
497
|
_impl: Union[
|
|
@@ -574,19 +559,7 @@ class _StreamReader(Generic[T]):
|
|
|
574
559
|
return self._impl.file_descriptor
|
|
575
560
|
|
|
576
561
|
async def read(self) -> T:
|
|
577
|
-
"""Fetch the entire contents of the stream until EOF.
|
|
578
|
-
|
|
579
|
-
**Usage**
|
|
580
|
-
|
|
581
|
-
```python fixture:running_app
|
|
582
|
-
from modal import Sandbox
|
|
583
|
-
|
|
584
|
-
sandbox = Sandbox.create("echo", "hello", app=running_app)
|
|
585
|
-
sandbox.wait()
|
|
586
|
-
|
|
587
|
-
print(sandbox.stdout.read())
|
|
588
|
-
```
|
|
589
|
-
"""
|
|
562
|
+
"""Fetch the entire contents of the stream until EOF."""
|
|
590
563
|
return await self._impl.read()
|
|
591
564
|
|
|
592
565
|
# TODO(saltzm): I'd prefer to have the implementation classes only implement __aiter__
|
|
@@ -757,21 +730,16 @@ class _StreamWriter:
|
|
|
757
730
|
|
|
758
731
|
**Usage**
|
|
759
732
|
|
|
760
|
-
```python fixture:
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
sandbox = Sandbox.create(
|
|
733
|
+
```python fixture:sandbox
|
|
734
|
+
proc = sandbox.exec(
|
|
764
735
|
"bash",
|
|
765
736
|
"-c",
|
|
766
737
|
"while read line; do echo $line; done",
|
|
767
|
-
app=running_app,
|
|
768
738
|
)
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
sandbox.stdin.drain()
|
|
774
|
-
sandbox.wait()
|
|
739
|
+
proc.stdin.write(b"foo\\n")
|
|
740
|
+
proc.stdin.write(b"bar\\n")
|
|
741
|
+
proc.stdin.write_eof()
|
|
742
|
+
proc.stdin.drain()
|
|
775
743
|
```
|
|
776
744
|
"""
|
|
777
745
|
self._impl.write(data)
|
|
@@ -182,21 +182,6 @@ class _StreamReader(typing.Generic[T]):
|
|
|
182
182
|
|
|
183
183
|
As an asynchronous iterable, the object supports the `for` and `async for`
|
|
184
184
|
statements. Just loop over the object to read in chunks.
|
|
185
|
-
|
|
186
|
-
**Usage**
|
|
187
|
-
|
|
188
|
-
```python fixture:running_app
|
|
189
|
-
from modal import Sandbox
|
|
190
|
-
|
|
191
|
-
sandbox = Sandbox.create(
|
|
192
|
-
"bash",
|
|
193
|
-
"-c",
|
|
194
|
-
"for i in $(seq 1 10); do echo foo; sleep 0.1; done",
|
|
195
|
-
app=running_app,
|
|
196
|
-
)
|
|
197
|
-
for message in sandbox.stdout:
|
|
198
|
-
print(f"Message: {message}")
|
|
199
|
-
```
|
|
200
185
|
"""
|
|
201
186
|
|
|
202
187
|
_impl: typing.Union[
|
|
@@ -228,19 +213,7 @@ class _StreamReader(typing.Generic[T]):
|
|
|
228
213
|
...
|
|
229
214
|
|
|
230
215
|
async def read(self) -> T:
|
|
231
|
-
"""Fetch the entire contents of the stream until EOF.
|
|
232
|
-
|
|
233
|
-
**Usage**
|
|
234
|
-
|
|
235
|
-
```python fixture:running_app
|
|
236
|
-
from modal import Sandbox
|
|
237
|
-
|
|
238
|
-
sandbox = Sandbox.create("echo", "hello", app=running_app)
|
|
239
|
-
sandbox.wait()
|
|
240
|
-
|
|
241
|
-
print(sandbox.stdout.read())
|
|
242
|
-
```
|
|
243
|
-
"""
|
|
216
|
+
"""Fetch the entire contents of the stream until EOF."""
|
|
244
217
|
...
|
|
245
218
|
|
|
246
219
|
def __aiter__(self) -> collections.abc.AsyncIterator[T]:
|
|
@@ -324,21 +297,16 @@ class _StreamWriter:
|
|
|
324
297
|
|
|
325
298
|
**Usage**
|
|
326
299
|
|
|
327
|
-
```python fixture:
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
sandbox = Sandbox.create(
|
|
300
|
+
```python fixture:sandbox
|
|
301
|
+
proc = sandbox.exec(
|
|
331
302
|
"bash",
|
|
332
303
|
"-c",
|
|
333
304
|
"while read line; do echo $line; done",
|
|
334
|
-
app=running_app,
|
|
335
305
|
)
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
sandbox.stdin.drain()
|
|
341
|
-
sandbox.wait()
|
|
306
|
+
proc.stdin.write(b"foo\n")
|
|
307
|
+
proc.stdin.write(b"bar\n")
|
|
308
|
+
proc.stdin.write_eof()
|
|
309
|
+
proc.stdin.drain()
|
|
342
310
|
```
|
|
343
311
|
"""
|
|
344
312
|
...
|
|
@@ -382,21 +350,6 @@ class StreamReader(typing.Generic[T]):
|
|
|
382
350
|
|
|
383
351
|
As an asynchronous iterable, the object supports the `for` and `async for`
|
|
384
352
|
statements. Just loop over the object to read in chunks.
|
|
385
|
-
|
|
386
|
-
**Usage**
|
|
387
|
-
|
|
388
|
-
```python fixture:running_app
|
|
389
|
-
from modal import Sandbox
|
|
390
|
-
|
|
391
|
-
sandbox = Sandbox.create(
|
|
392
|
-
"bash",
|
|
393
|
-
"-c",
|
|
394
|
-
"for i in $(seq 1 10); do echo foo; sleep 0.1; done",
|
|
395
|
-
app=running_app,
|
|
396
|
-
)
|
|
397
|
-
for message in sandbox.stdout:
|
|
398
|
-
print(f"Message: {message}")
|
|
399
|
-
```
|
|
400
353
|
"""
|
|
401
354
|
|
|
402
355
|
_impl: typing.Union[
|
|
@@ -429,35 +382,11 @@ class StreamReader(typing.Generic[T]):
|
|
|
429
382
|
|
|
430
383
|
class __read_spec(typing_extensions.Protocol[T_INNER, SUPERSELF]):
|
|
431
384
|
def __call__(self, /) -> T_INNER:
|
|
432
|
-
"""Fetch the entire contents of the stream until EOF.
|
|
433
|
-
|
|
434
|
-
**Usage**
|
|
435
|
-
|
|
436
|
-
```python fixture:running_app
|
|
437
|
-
from modal import Sandbox
|
|
438
|
-
|
|
439
|
-
sandbox = Sandbox.create("echo", "hello", app=running_app)
|
|
440
|
-
sandbox.wait()
|
|
441
|
-
|
|
442
|
-
print(sandbox.stdout.read())
|
|
443
|
-
```
|
|
444
|
-
"""
|
|
385
|
+
"""Fetch the entire contents of the stream until EOF."""
|
|
445
386
|
...
|
|
446
387
|
|
|
447
388
|
async def aio(self, /) -> T_INNER:
|
|
448
|
-
"""Fetch the entire contents of the stream until EOF.
|
|
449
|
-
|
|
450
|
-
**Usage**
|
|
451
|
-
|
|
452
|
-
```python fixture:running_app
|
|
453
|
-
from modal import Sandbox
|
|
454
|
-
|
|
455
|
-
sandbox = Sandbox.create("echo", "hello", app=running_app)
|
|
456
|
-
sandbox.wait()
|
|
457
|
-
|
|
458
|
-
print(sandbox.stdout.read())
|
|
459
|
-
```
|
|
460
|
-
"""
|
|
389
|
+
"""Fetch the entire contents of the stream until EOF."""
|
|
461
390
|
...
|
|
462
391
|
|
|
463
392
|
read: __read_spec[T, typing_extensions.Self]
|
|
@@ -507,21 +436,16 @@ class StreamWriter:
|
|
|
507
436
|
|
|
508
437
|
**Usage**
|
|
509
438
|
|
|
510
|
-
```python fixture:
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
sandbox = Sandbox.create(
|
|
439
|
+
```python fixture:sandbox
|
|
440
|
+
proc = sandbox.exec(
|
|
514
441
|
"bash",
|
|
515
442
|
"-c",
|
|
516
443
|
"while read line; do echo $line; done",
|
|
517
|
-
app=running_app,
|
|
518
444
|
)
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
sandbox.stdin.drain()
|
|
524
|
-
sandbox.wait()
|
|
445
|
+
proc.stdin.write(b"foo\n")
|
|
446
|
+
proc.stdin.write(b"bar\n")
|
|
447
|
+
proc.stdin.write_eof()
|
|
448
|
+
proc.stdin.drain()
|
|
525
449
|
```
|
|
526
450
|
"""
|
|
527
451
|
...
|
|
@@ -805,13 +805,8 @@ class _Sandbox(_Object, type_prefix="sb"):
|
|
|
805
805
|
|
|
806
806
|
**Usage**
|
|
807
807
|
|
|
808
|
-
```python
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
sandbox = modal.Sandbox.create("sleep", "infinity", app=app)
|
|
812
|
-
|
|
813
|
-
process = sandbox.exec("bash", "-c", "for i in $(seq 1 10); do echo foo $i; sleep 0.5; done")
|
|
814
|
-
|
|
808
|
+
```python fixture:sandbox
|
|
809
|
+
process = sandbox.exec("bash", "-c", "for i in $(seq 1 3); do echo foo $i; sleep 0.1; done")
|
|
815
810
|
for line in process.stdout:
|
|
816
811
|
print(line)
|
|
817
812
|
```
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|