modal 0.67.43__py3-none-any.whl → 0.68.24__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.
Files changed (52) hide show
  1. modal/__init__.py +2 -0
  2. modal/_container_entrypoint.py +4 -1
  3. modal/_ipython.py +3 -13
  4. modal/_runtime/asgi.py +4 -0
  5. modal/_runtime/container_io_manager.py +3 -0
  6. modal/_runtime/user_code_imports.py +17 -20
  7. modal/_traceback.py +16 -2
  8. modal/_utils/blob_utils.py +27 -92
  9. modal/_utils/bytes_io_segment_payload.py +97 -0
  10. modal/_utils/function_utils.py +5 -1
  11. modal/_utils/grpc_testing.py +6 -2
  12. modal/_utils/hash_utils.py +51 -10
  13. modal/_utils/http_utils.py +19 -10
  14. modal/_utils/{pattern_matcher.py → pattern_utils.py} +1 -70
  15. modal/_utils/shell_utils.py +11 -5
  16. modal/cli/_traceback.py +11 -4
  17. modal/cli/run.py +25 -12
  18. modal/client.py +6 -37
  19. modal/client.pyi +2 -6
  20. modal/cls.py +132 -62
  21. modal/cls.pyi +13 -7
  22. modal/exception.py +20 -0
  23. modal/file_io.py +380 -0
  24. modal/file_io.pyi +185 -0
  25. modal/file_pattern_matcher.py +121 -0
  26. modal/functions.py +33 -11
  27. modal/functions.pyi +11 -9
  28. modal/image.py +88 -8
  29. modal/image.pyi +20 -4
  30. modal/mount.py +49 -9
  31. modal/mount.pyi +19 -4
  32. modal/network_file_system.py +4 -1
  33. modal/object.py +4 -2
  34. modal/partial_function.py +22 -10
  35. modal/partial_function.pyi +10 -2
  36. modal/runner.py +5 -4
  37. modal/runner.pyi +2 -1
  38. modal/sandbox.py +40 -0
  39. modal/sandbox.pyi +18 -0
  40. modal/volume.py +5 -1
  41. {modal-0.67.43.dist-info → modal-0.68.24.dist-info}/METADATA +2 -2
  42. {modal-0.67.43.dist-info → modal-0.68.24.dist-info}/RECORD +52 -48
  43. modal_docs/gen_reference_docs.py +1 -0
  44. modal_proto/api.proto +33 -1
  45. modal_proto/api_pb2.py +813 -737
  46. modal_proto/api_pb2.pyi +160 -13
  47. modal_version/__init__.py +1 -1
  48. modal_version/_version_generated.py +1 -1
  49. {modal-0.67.43.dist-info → modal-0.68.24.dist-info}/LICENSE +0 -0
  50. {modal-0.67.43.dist-info → modal-0.68.24.dist-info}/WHEEL +0 -0
  51. {modal-0.67.43.dist-info → modal-0.68.24.dist-info}/entry_points.txt +0 -0
  52. {modal-0.67.43.dist-info → modal-0.68.24.dist-info}/top_level.txt +0 -0
modal_proto/api.proto CHANGED
@@ -360,6 +360,12 @@ message AppHeartbeatRequest {
360
360
  string app_id = 1;
361
361
  }
362
362
 
363
+ message AppLayout {
364
+ repeated Object object = 1;
365
+ map<string, string> function_ids = 2; // tag -> function id
366
+ map<string, string> class_ids = 3; // tag -> class id
367
+ }
368
+
363
369
  message AppListRequest {
364
370
  string environment_name = 1;
365
371
  }
@@ -400,7 +406,6 @@ message AppPublishRequest {
400
406
 
401
407
  message AppPublishResponse {
402
408
  string url = 1;
403
- repeated string warnings = 2; // Deprecated soon in favor of server_warnings
404
409
  repeated Warning server_warnings = 3;
405
410
  }
406
411
 
@@ -679,6 +684,7 @@ message ClassParameterValue {
679
684
  message ClientHelloResponse {
680
685
  string warning = 1;
681
686
  string image_builder_version = 2; // Deprecated, no longer used in client
687
+ repeated Warning server_warnings = 4;
682
688
  }
683
689
 
684
690
  message CloudBucketMount {
@@ -710,6 +716,7 @@ message ContainerArguments { // This is used to pass data from the worker to th
710
716
  string runtime = 11;
711
717
  string environment_name = 13;
712
718
  optional string checkpoint_id = 14;
719
+ AppLayout app_layout = 15;
713
720
  }
714
721
 
715
722
  message ContainerCheckpointRequest {
@@ -772,6 +779,15 @@ message ContainerFileFlushRequest {
772
779
  string file_descriptor = 1;
773
780
  }
774
781
 
782
+ message ContainerFileLsRequest {
783
+ string path = 1;
784
+ }
785
+
786
+ message ContainerFileMkdirRequest {
787
+ string path = 1;
788
+ bool make_parents = 2;
789
+ }
790
+
775
791
  message ContainerFileOpenRequest {
776
792
  // file descriptor is hydrated when sent from server -> worker
777
793
  optional string file_descriptor = 1;
@@ -788,12 +804,23 @@ message ContainerFileReadRequest {
788
804
  optional uint32 n = 2;
789
805
  }
790
806
 
807
+ message ContainerFileRmRequest {
808
+ string path = 1;
809
+ bool recursive = 2;
810
+ }
811
+
791
812
  message ContainerFileSeekRequest {
792
813
  string file_descriptor = 1;
793
814
  int32 offset = 2;
794
815
  SeekWhence whence = 3;
795
816
  }
796
817
 
818
+ message ContainerFileWatchRequest {
819
+ string path = 1;
820
+ bool recursive = 2;
821
+ optional uint64 timeout_secs = 3;
822
+ }
823
+
797
824
  message ContainerFileWriteReplaceBytesRequest {
798
825
  string file_descriptor = 1;
799
826
  bytes data = 2;
@@ -822,6 +849,10 @@ message ContainerFilesystemExecRequest {
822
849
  ContainerFileDeleteBytesRequest file_delete_bytes_request = 7;
823
850
  ContainerFileWriteReplaceBytesRequest file_write_replace_bytes_request = 8;
824
851
  ContainerFileCloseRequest file_close_request = 9;
852
+ ContainerFileLsRequest file_ls_request = 11;
853
+ ContainerFileMkdirRequest file_mkdir_request = 12;
854
+ ContainerFileRmRequest file_rm_request = 13;
855
+ ContainerFileWatchRequest file_watch_request = 14;
825
856
  }
826
857
  string task_id = 10;
827
858
  }
@@ -2653,6 +2684,7 @@ message WebhookConfig {
2653
2684
  uint32 web_server_port = 7;
2654
2685
  float web_server_startup_timeout = 8;
2655
2686
  bool web_endpoint_docs = 9;
2687
+ bool requires_proxy_auth = 10;
2656
2688
  }
2657
2689
 
2658
2690
  message WorkspaceNameLookupResponse {