e2b 2.53.1__tar.gz → 2.55.0__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.
Files changed (247) hide show
  1. {e2b-2.53.1 → e2b-2.55.0}/PKG-INFO +2 -2
  2. {e2b-2.53.1 → e2b-2.55.0}/e2b/__init__.py +4 -0
  3. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_templates.py +8 -4
  4. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_v2_templates.py +8 -4
  5. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/error.py +1 -1
  6. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_snapshot_request.py +12 -0
  7. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_request_v3.py +1 -1
  8. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/filesystem/filesystem_pb.py +11 -3
  9. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/filesystem/filesystem.py +3 -1
  10. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/sandbox_api.py +78 -43
  11. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/commands/command_handle.py +3 -3
  12. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/main.py +35 -5
  13. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/sandbox_api.py +11 -2
  14. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/commands/command_handle.py +3 -3
  15. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/main.py +35 -5
  16. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/sandbox_api.py +11 -2
  17. e2b-2.55.0/e2b/template/dockerfile_parser.py +634 -0
  18. {e2b-2.53.1 → e2b-2.55.0}/e2b/template/main.py +2 -2
  19. {e2b-2.53.1 → e2b-2.55.0}/e2b/template/utils.py +9 -5
  20. {e2b-2.53.1 → e2b-2.55.0}/pyproject.toml +5 -2
  21. e2b-2.53.1/e2b/template/dockerfile_parser.py +0 -286
  22. e2b-2.53.1/e2b/template/dockerignore.py +0 -206
  23. {e2b-2.53.1 → e2b-2.55.0}/README.md +0 -0
  24. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/__init__.py +0 -0
  25. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/__init__.py +0 -0
  26. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/__init__.py +0 -0
  27. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/__init__.py +0 -0
  28. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/delete_sandboxes_sandbox_id.py +0 -0
  29. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_sandboxes.py +0 -0
  30. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_sandboxes_metrics.py +0 -0
  31. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_sandboxes_sandbox_id.py +0 -0
  32. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_sandboxes_sandbox_id_logs.py +0 -0
  33. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_sandboxes_sandbox_id_metrics.py +0 -0
  34. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_v2_sandboxes.py +0 -0
  35. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/get_v_2_sandboxes_sandbox_id_logs.py +0 -0
  36. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes.py +0 -0
  37. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_connect.py +0 -0
  38. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_fork.py +0 -0
  39. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_pause.py +0 -0
  40. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_refreshes.py +0 -0
  41. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_resume.py +0 -0
  42. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_snapshots.py +0 -0
  43. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_sandboxes_sandbox_id_timeout.py +0 -0
  44. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_v2_sandboxes.py +0 -0
  45. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/post_v_2_sandboxes_sandbox_id_connect.py +0 -0
  46. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/sandboxes/put_sandboxes_sandbox_id_network.py +0 -0
  47. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/secrets/__init__.py +0 -0
  48. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/secrets/delete_secrets_secret_id.py +0 -0
  49. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/secrets/get_secrets.py +0 -0
  50. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/secrets/get_secrets_secret_id.py +0 -0
  51. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/secrets/post_secrets.py +0 -0
  52. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/secrets/post_secrets_secret_id.py +0 -0
  53. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/snapshots/__init__.py +0 -0
  54. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/snapshots/get_snapshots.py +0 -0
  55. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/tags/__init__.py +0 -0
  56. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/tags/delete_templates_tags.py +0 -0
  57. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/tags/get_templates_template_id_tags.py +0 -0
  58. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/tags/post_templates_tags.py +0 -0
  59. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/__init__.py +0 -0
  60. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/delete_templates_template_id.py +0 -0
  61. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_templates_aliases_alias.py +0 -0
  62. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_templates_template_id.py +0 -0
  63. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_templates_template_id_builds_build_id_logs.py +0 -0
  64. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_templates_template_id_builds_build_id_status.py +0 -0
  65. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/get_templates_template_id_files_hash.py +0 -0
  66. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/patch_templates_template_id.py +0 -0
  67. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/patch_v_2_templates_template_id.py +0 -0
  68. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/post_v3_templates.py +0 -0
  69. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/templates/post_v_2_templates_template_id_builds_build_id.py +0 -0
  70. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/volumes/__init__.py +0 -0
  71. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/volumes/delete_volumes_volume_id.py +0 -0
  72. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/volumes/get_volumes.py +0 -0
  73. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/volumes/get_volumes_volume_id.py +0 -0
  74. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/api/volumes/post_volumes.py +0 -0
  75. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/client.py +0 -0
  76. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/errors.py +0 -0
  77. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/__init__.py +0 -0
  78. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/assign_template_tags_request.py +0 -0
  79. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/assigned_template_tags.py +0 -0
  80. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/aws_registry.py +0 -0
  81. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/aws_registry_type.py +0 -0
  82. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/build_log_entry.py +0 -0
  83. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/build_status_reason.py +0 -0
  84. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/connect_sandbox.py +0 -0
  85. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/connect_sandbox_v2.py +0 -0
  86. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/delete_template_tags_request.py +0 -0
  87. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/gcp_registry.py +0 -0
  88. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/gcp_registry_type.py +0 -0
  89. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/general_registry.py +0 -0
  90. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/general_registry_type.py +0 -0
  91. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/listed_sandbox.py +0 -0
  92. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/log_level.py +0 -0
  93. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/logs_direction.py +0 -0
  94. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/logs_source.py +0 -0
  95. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/mcp_type_0.py +0 -0
  96. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/new_sandbox.py +0 -0
  97. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/new_sandbox_v2.py +0 -0
  98. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/new_secret.py +0 -0
  99. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/new_volume.py +0 -0
  100. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/order_direction.py +0 -0
  101. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/resumed_sandbox.py +0 -0
  102. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox.py +0 -0
  103. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_auto_resume_config.py +0 -0
  104. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_detail.py +0 -0
  105. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_egress_proxy_config_type_0.py +0 -0
  106. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_fork_request.py +0 -0
  107. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_fork_result.py +0 -0
  108. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_iam.py +0 -0
  109. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_iam_token.py +0 -0
  110. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_iam_tokens.py +0 -0
  111. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_lifecycle.py +0 -0
  112. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_log.py +0 -0
  113. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_log_entry.py +0 -0
  114. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_log_entry_fields.py +0 -0
  115. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_logs.py +0 -0
  116. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_logs_v2_response.py +0 -0
  117. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_metric.py +0 -0
  118. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_config.py +0 -0
  119. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_config_rules.py +0 -0
  120. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_rule.py +0 -0
  121. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_transform.py +0 -0
  122. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_transform_headers.py +0 -0
  123. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_update_config.py +0 -0
  124. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_network_update_config_rules.py +0 -0
  125. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_on_timeout.py +0 -0
  126. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_pause_request.py +0 -0
  127. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_refresh_request.py +0 -0
  128. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_state.py +0 -0
  129. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_timeout_request.py +0 -0
  130. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandbox_volume_mount.py +0 -0
  131. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/sandboxes_with_metrics.py +0 -0
  132. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/secret.py +0 -0
  133. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/secret_metadata.py +0 -0
  134. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/secret_update.py +0 -0
  135. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/snapshot_info.py +0 -0
  136. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/team_user.py +0 -0
  137. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template.py +0 -0
  138. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_alias_response.py +0 -0
  139. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build.py +0 -0
  140. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_file_upload.py +0 -0
  141. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_file_upload_headers.py +0 -0
  142. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_info.py +0 -0
  143. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_logs_response.py +0 -0
  144. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_start_v2.py +0 -0
  145. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_build_status.py +0 -0
  146. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_request_response_v3.py +0 -0
  147. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_step.py +0 -0
  148. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_tag.py +0 -0
  149. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_update_request.py +0 -0
  150. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_update_response.py +0 -0
  151. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/template_with_builds.py +0 -0
  152. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/volume.py +0 -0
  153. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/models/volume_and_token.py +0 -0
  154. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/py.typed +0 -0
  155. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client/types.py +0 -0
  156. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client_async/__init__.py +0 -0
  157. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/client_sync/__init__.py +0 -0
  158. {e2b-2.53.1 → e2b-2.55.0}/e2b/api/metadata.py +0 -0
  159. {e2b-2.53.1 → e2b-2.55.0}/e2b/client.py +0 -0
  160. {e2b-2.53.1 → e2b-2.55.0}/e2b/connection_config.py +0 -0
  161. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/__init__.py +0 -0
  162. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/api.py +0 -0
  163. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/client_async/__init__.py +0 -0
  164. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/client_shared.py +0 -0
  165. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/client_sync/__init__.py +0 -0
  166. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/filesystem/__init__.py +0 -0
  167. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/filesystem/filesystem_connect.py +0 -0
  168. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/interceptors.py +0 -0
  169. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/process/__init__.py +0 -0
  170. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/process/process_connect.py +0 -0
  171. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/process/process_pb.py +0 -0
  172. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/rpc.py +0 -0
  173. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/utils.py +0 -0
  174. {e2b-2.53.1 → e2b-2.55.0}/e2b/envd/versions.py +0 -0
  175. {e2b-2.53.1 → e2b-2.55.0}/e2b/exceptions.py +0 -0
  176. {e2b-2.53.1 → e2b-2.55.0}/e2b/io_utils.py +0 -0
  177. {e2b-2.53.1 → e2b-2.55.0}/e2b/paginator.py +0 -0
  178. {e2b-2.53.1 → e2b-2.55.0}/e2b/py.typed +0 -0
  179. {e2b-2.53.1 → e2b-2.55.0}/e2b/retry.py +0 -0
  180. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/_git/__init__.py +0 -0
  181. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/_git/args.py +0 -0
  182. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/_git/auth.py +0 -0
  183. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/_git/config.py +0 -0
  184. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/_git/parse.py +0 -0
  185. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/_git/types.py +0 -0
  186. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/commands/command_handle.py +0 -0
  187. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/commands/main.py +0 -0
  188. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/filesystem/watch_handle.py +0 -0
  189. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/iam.py +0 -0
  190. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/main.py +0 -0
  191. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/mcp.py +0 -0
  192. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/network.py +0 -0
  193. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/signature.py +0 -0
  194. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox/utils.py +0 -0
  195. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/commands/command.py +0 -0
  196. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/commands/pty.py +0 -0
  197. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/filesystem/filesystem.py +0 -0
  198. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/filesystem/watch_handle.py +0 -0
  199. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/git.py +0 -0
  200. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/paginator.py +0 -0
  201. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_async/utils.py +0 -0
  202. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_domains.py +0 -0
  203. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/commands/command.py +0 -0
  204. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/commands/pty.py +0 -0
  205. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/filesystem/filesystem.py +0 -0
  206. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/filesystem/watch_handle.py +0 -0
  207. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/git.py +0 -0
  208. {e2b-2.53.1 → e2b-2.55.0}/e2b/sandbox_sync/paginator.py +0 -0
  209. {e2b-2.53.1 → e2b-2.55.0}/e2b/secret/__init__.py +0 -0
  210. {e2b-2.53.1 → e2b-2.55.0}/e2b/secret/base.py +0 -0
  211. {e2b-2.53.1 → e2b-2.55.0}/e2b/secret/secret_async.py +0 -0
  212. {e2b-2.53.1 → e2b-2.55.0}/e2b/secret/secret_sync.py +0 -0
  213. {e2b-2.53.1 → e2b-2.55.0}/e2b/secret/types.py +0 -0
  214. {e2b-2.53.1 → e2b-2.55.0}/e2b/template/consts.py +0 -0
  215. {e2b-2.53.1 → e2b-2.55.0}/e2b/template/logger.py +0 -0
  216. {e2b-2.53.1 → e2b-2.55.0}/e2b/template/readycmd.py +0 -0
  217. {e2b-2.53.1 → e2b-2.55.0}/e2b/template/types.py +0 -0
  218. {e2b-2.53.1 → e2b-2.55.0}/e2b/template_async/build_api.py +0 -0
  219. {e2b-2.53.1 → e2b-2.55.0}/e2b/template_async/main.py +0 -0
  220. {e2b-2.53.1 → e2b-2.55.0}/e2b/template_sync/build_api.py +0 -0
  221. {e2b-2.53.1 → e2b-2.55.0}/e2b/template_sync/main.py +0 -0
  222. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/__init__.py +0 -0
  223. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/__init__.py +0 -0
  224. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/__init__.py +0 -0
  225. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/delete_volumecontent_volume_id_path.py +0 -0
  226. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/get_volumecontent_volume_id_dir.py +0 -0
  227. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/get_volumecontent_volume_id_file.py +0 -0
  228. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/get_volumecontent_volume_id_path.py +0 -0
  229. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/patch_volumecontent_volume_id_path.py +0 -0
  230. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/post_volumecontent_volume_id_dir.py +0 -0
  231. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/api/volumes/put_volumecontent_volume_id_file.py +0 -0
  232. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/client.py +0 -0
  233. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/errors.py +0 -0
  234. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/models/__init__.py +0 -0
  235. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/models/error.py +0 -0
  236. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/models/patch_volumecontent_volume_id_path_body.py +0 -0
  237. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/models/volume_entry_stat.py +0 -0
  238. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/models/volume_entry_stat_type.py +0 -0
  239. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/py.typed +0 -0
  240. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client/types.py +0 -0
  241. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client_async/__init__.py +0 -0
  242. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/client_sync/__init__.py +0 -0
  243. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/connection_config.py +0 -0
  244. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/types.py +0 -0
  245. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/utils.py +0 -0
  246. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/volume_async.py +0 -0
  247. {e2b-2.53.1 → e2b-2.55.0}/e2b/volume/volume_sync.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: e2b
3
- Version: 2.53.1
3
+ Version: 2.55.0
4
4
  Summary: E2B SDK that give agents cloud environments
5
5
  Author: e2b
6
6
  Author-email: e2b <hello@e2b.dev>
@@ -13,10 +13,10 @@ Requires-Dist: h2>=4.4.1,<5
13
13
  Requires-Dist: attrs>=23.2.0
14
14
  Requires-Dist: packaging>=24.1
15
15
  Requires-Dist: typing-extensions>=4.10.0
16
- Requires-Dist: dockerfile-parse>=2.0.1,<3
17
16
  Requires-Dist: rich>=14.0.0
18
17
  Requires-Dist: connectrpc>=0.11.1,<0.12
19
18
  Requires-Dist: pyqwest>=0.10.0,<0.11
19
+ Requires-Dist: e2b-dockerfile-utils>=0.1.0,<0.2
20
20
  Requires-Python: >=3.10
21
21
  Project-URL: Homepage, https://e2b.dev/?utm_source=pypi&utm_medium=referral&utm_campaign=package_homepage&utm_content=e2b
22
22
  Project-URL: Repository, https://github.com/e2b-dev/e2b/tree/main/packages/python-sdk
@@ -109,6 +109,7 @@ from .sandbox.sandbox_api import (
109
109
  SandboxQuery,
110
110
  SandboxState,
111
111
  SnapshotInfo,
112
+ SnapshotMode,
112
113
  )
113
114
  from .sandbox_async.commands.command_handle import AsyncCommandHandle
114
115
  from .sandbox_async.filesystem.watch_handle import AsyncWatchHandle
@@ -133,6 +134,7 @@ from .template.logger import (
133
134
  LogEntryStart,
134
135
  default_build_logger,
135
136
  )
137
+ from .template.dockerfile_parser import DockerfileSyntaxError
136
138
  from .template.main import TemplateBase, TemplateClass
137
139
  from .template.readycmd import (
138
140
  ReadyCmd,
@@ -194,6 +196,7 @@ __all__ = [
194
196
  "InvalidArgumentException",
195
197
  "NotEnoughSpaceException",
196
198
  "TemplateException",
199
+ "DockerfileSyntaxError",
197
200
  "BuildException",
198
201
  "FileUploadException",
199
202
  "RateLimitException",
@@ -257,6 +260,7 @@ __all__ = [
257
260
  "SecretNotFoundException",
258
261
  # Snapshot
259
262
  "SnapshotInfo",
263
+ "SnapshotMode",
260
264
  "SnapshotPaginator",
261
265
  "AsyncSnapshotPaginator",
262
266
  # Signature
@@ -80,7 +80,8 @@ def sync_detailed(
80
80
  List all templates
81
81
 
82
82
  Args:
83
- team_id (Union[Unset, str]): Identifier of the team
83
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
84
+ (prj_)
84
85
 
85
86
  Raises:
86
87
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
@@ -111,7 +112,8 @@ def sync(
111
112
  List all templates
112
113
 
113
114
  Args:
114
- team_id (Union[Unset, str]): Identifier of the team
115
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
116
+ (prj_)
115
117
 
116
118
  Raises:
117
119
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
@@ -137,7 +139,8 @@ async def asyncio_detailed(
137
139
  List all templates
138
140
 
139
141
  Args:
140
- team_id (Union[Unset, str]): Identifier of the team
142
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
143
+ (prj_)
141
144
 
142
145
  Raises:
143
146
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
@@ -166,7 +169,8 @@ async def asyncio(
166
169
  List all templates
167
170
 
168
171
  Args:
169
- team_id (Union[Unset, str]): Identifier of the team
172
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
173
+ (prj_)
170
174
 
171
175
  Raises:
172
176
  errors.UnexpectedStatus: If the server returns an undocumented status code and Client.raise_on_unexpected_status is True.
@@ -96,7 +96,8 @@ def sync_detailed(
96
96
  List all templates
97
97
 
98
98
  Args:
99
- team_id (Union[Unset, str]): Identifier of the team
99
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
100
+ (prj_)
100
101
  next_token (Union[Unset, str]):
101
102
  limit (Union[Unset, int]): Default: 100.
102
103
 
@@ -133,7 +134,8 @@ def sync(
133
134
  List all templates
134
135
 
135
136
  Args:
136
- team_id (Union[Unset, str]): Identifier of the team
137
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
138
+ (prj_)
137
139
  next_token (Union[Unset, str]):
138
140
  limit (Union[Unset, int]): Default: 100.
139
141
 
@@ -165,7 +167,8 @@ async def asyncio_detailed(
165
167
  List all templates
166
168
 
167
169
  Args:
168
- team_id (Union[Unset, str]): Identifier of the team
170
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
171
+ (prj_)
169
172
  next_token (Union[Unset, str]):
170
173
  limit (Union[Unset, int]): Default: 100.
171
174
 
@@ -200,7 +203,8 @@ async def asyncio(
200
203
  List all templates
201
204
 
202
205
  Args:
203
- team_id (Union[Unset, str]): Identifier of the team
206
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID
207
+ (prj_)
204
208
  next_token (Union[Unset, str]):
205
209
  limit (Union[Unset, int]): Default: 100.
206
210
 
@@ -17,7 +17,7 @@ class Error:
17
17
  message (str): Error
18
18
  error_code (Union[Unset, str]): Machine-readable semantic error code. Not a closed set; initial values:
19
19
  sandbox_capacity_unavailable, sandbox_placement_timeout, sandbox_no_compatible_node, sandbox_create_failed,
20
- internal_server_error.
20
+ internal_server_error, secret_limit_reached.
21
21
  """
22
22
 
23
23
  code: int
@@ -15,19 +15,28 @@ class SandboxSnapshotRequest:
15
15
  Attributes:
16
16
  name (Union[Unset, str]): Optional name for the snapshot template. If a snapshot template with this name already
17
17
  exists, a new build will be assigned to the existing template instead of creating a new one.
18
+ memory (Union[Unset, bool]): Whether to capture a full memory snapshot. When false, only the filesystem is
19
+ persisted: the snapshot is smaller and faster to take, and sandboxes created from it cold-boot (start fresh from
20
+ disk) instead of restoring memory, so they begin without the source sandbox's running processes, in-memory
21
+ state, and open connections. The source sandbox keeps running in both cases. Defaults to true.
18
22
  """
19
23
 
20
24
  name: Union[Unset, str] = UNSET
25
+ memory: Union[Unset, bool] = UNSET
21
26
  additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
22
27
 
23
28
  def to_dict(self) -> dict[str, Any]:
24
29
  name = self.name
25
30
 
31
+ memory = self.memory
32
+
26
33
  field_dict: dict[str, Any] = {}
27
34
  field_dict.update(self.additional_properties)
28
35
  field_dict.update({})
29
36
  if name is not UNSET:
30
37
  field_dict["name"] = name
38
+ if memory is not UNSET:
39
+ field_dict["memory"] = memory
31
40
 
32
41
  return field_dict
33
42
 
@@ -36,8 +45,11 @@ class SandboxSnapshotRequest:
36
45
  d = dict(src_dict)
37
46
  name = d.pop("name", UNSET)
38
47
 
48
+ memory = d.pop("memory", UNSET)
49
+
39
50
  sandbox_snapshot_request = cls(
40
51
  name=name,
52
+ memory=memory,
41
53
  )
42
54
 
43
55
  sandbox_snapshot_request.additional_properties = d
@@ -17,7 +17,7 @@ class TemplateBuildRequestV3:
17
17
  "my-template:v1"). If tag is included, it will be treated as if the tag was provided in the tags array.
18
18
  tags (Union[Unset, list[str]]): Tags to assign to the template build
19
19
  alias (Union[Unset, str]): Alias of the template. Deprecated, use name instead.
20
- team_id (Union[Unset, str]): Identifier of the team
20
+ team_id (Union[Unset, str]): Identifier of the team, as its UUID or its public project ID (prj_)
21
21
  cpu_count (Union[Unset, int]): CPU cores for the sandbox
22
22
  memory_mb (Union[Unset, int]): Memory for the sandbox in MiB
23
23
  min_free_disk_mb (Union[Unset, int]): Requested minimum free space after the template's build steps, in MiB.
@@ -237,7 +237,7 @@ class StatResponse(Message[_StatResponseFields]):
237
237
 
238
238
  entry: EntryInfo | None
239
239
 
240
- _EntryInfoFields: TypeAlias = Literal["name", "type", "path", "size", "mode", "permissions", "owner", "group", "modified_time", "symlink_target", "metadata"]
240
+ _EntryInfoFields: TypeAlias = Literal["name", "type", "path", "size", "mode", "permissions", "owner", "group", "modified_time", "symlink_target", "metadata", "is_symlink"]
241
241
 
242
242
  class EntryInfo(Message[_EntryInfoFields]):
243
243
  """
@@ -296,9 +296,15 @@ class EntryInfo(Message[_EntryInfoFields]):
296
296
  ```proto
297
297
  map<string, string> metadata = 11;
298
298
  ```
299
+ is_symlink:
300
+ True when the entry itself is a symlink; type then describes the symlink's target.
301
+
302
+ ```proto
303
+ bool is_symlink = 12;
304
+ ```
299
305
  """
300
306
 
301
- __slots__ = ("name", "type", "path", "size", "mode", "permissions", "owner", "group", "modified_time", "symlink_target", "metadata")
307
+ __slots__ = ("name", "type", "path", "size", "mode", "permissions", "owner", "group", "modified_time", "symlink_target", "metadata", "is_symlink")
302
308
 
303
309
  if TYPE_CHECKING:
304
310
 
@@ -316,6 +322,7 @@ class EntryInfo(Message[_EntryInfoFields]):
316
322
  modified_time: Timestamp | None = None,
317
323
  symlink_target: str | None = None,
318
324
  metadata: dict[str, str] | None = None,
325
+ is_symlink: bool = False,
319
326
  ) -> None:
320
327
  pass
321
328
 
@@ -330,6 +337,7 @@ class EntryInfo(Message[_EntryInfoFields]):
330
337
  modified_time: Timestamp | None
331
338
  symlink_target: str
332
339
  metadata: dict[str, str]
340
+ is_symlink: bool
333
341
 
334
342
  _ListDirRequestFields: TypeAlias = Literal["path", "depth"]
335
343
 
@@ -805,7 +813,7 @@ class EventType(Enum):
805
813
 
806
814
 
807
815
  _DESC = file_desc(
808
- b'\n\x1bfilesystem/filesystem.proto\x12\nfilesystem\x1a\x1fgoogle/protobuf/timestamp.proto"G\n\x0bMoveRequest\x12\x16\n\x06source\x18\x01 \x01(\tR\x06source\x12 \n\x0bdestination\x18\x02 \x01(\tR\x0bdestination";\n\x0cMoveResponse\x12+\n\x05entry\x18\x01 \x01(\x0b2\x15.filesystem.EntryInfoR\x05entry"$\n\x0eMakeDirRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path">\n\x0fMakeDirResponse\x12+\n\x05entry\x18\x01 \x01(\x0b2\x15.filesystem.EntryInfoR\x05entry"#\n\rRemoveRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path"\x10\n\x0eRemoveResponse"!\n\x0bStatRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path";\n\x0cStatResponse\x12+\n\x05entry\x18\x01 \x01(\x0b2\x15.filesystem.EntryInfoR\x05entry"\xd1\x03\n\tEntryInfo\x12\x12\n\x04name\x18\x01 \x01(\tR\x04name\x12(\n\x04type\x18\x02 \x01(\x0e2\x14.filesystem.FileTypeR\x04type\x12\x12\n\x04path\x18\x03 \x01(\tR\x04path\x12\x12\n\x04size\x18\x04 \x01(\x03R\x04size\x12\x12\n\x04mode\x18\x05 \x01(\rR\x04mode\x12 \n\x0bpermissions\x18\x06 \x01(\tR\x0bpermissions\x12\x14\n\x05owner\x18\x07 \x01(\tR\x05owner\x12\x14\n\x05group\x18\x08 \x01(\tR\x05group\x12?\n\rmodified_time\x18\t \x01(\x0b2\x1a.google.protobuf.TimestampR\x0cmodifiedTime\x12*\n\x0esymlink_target\x18\n \x01(\tH\x00R\rsymlinkTarget\x88\x01\x01\x12?\n\x08metadata\x18\x0b \x03(\x0b2#.filesystem.EntryInfo.MetadataEntryR\x08metadata\x1a;\n\rMetadataEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\x11\n\x0f_symlink_target":\n\x0eListDirRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12\x14\n\x05depth\x18\x02 \x01(\rR\x05depth"B\n\x0fListDirResponse\x12/\n\x07entries\x18\x01 \x03(\x0b2\x15.filesystem.EntryInfoR\x07entries"\x9a\x01\n\x0fWatchDirRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12\x1c\n\trecursive\x18\x02 \x01(\x08R\trecursive\x12#\n\rinclude_entry\x18\x03 \x01(\x08R\x0cincludeEntry\x120\n\x14allow_network_mounts\x18\x04 \x01(\x08R\x12allowNetworkMounts"\x8c\x01\n\x0fFilesystemEvent\x12\x12\n\x04name\x18\x01 \x01(\tR\x04name\x12)\n\x04type\x18\x02 \x01(\x0e2\x15.filesystem.EventTypeR\x04type\x120\n\x05entry\x18\x03 \x01(\x0b2\x15.filesystem.EntryInfoH\x00R\x05entry\x88\x01\x01B\x08\n\x06_entry"\xfe\x01\n\x10WatchDirResponse\x12?\n\x05start\x18\x01 \x01(\x0b2\'.filesystem.WatchDirResponse.StartEventH\x00R\x05start\x12=\n\nfilesystem\x18\x02 \x01(\x0b2\x1b.filesystem.FilesystemEventH\x00R\nfilesystem\x12F\n\tkeepalive\x18\x03 \x01(\x0b2&.filesystem.WatchDirResponse.KeepAliveH\x00R\tkeepalive\x1a\x0c\n\nStartEvent\x1a\x0b\n\tKeepAliveB\x07\n\x05event"\x9f\x01\n\x14CreateWatcherRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12\x1c\n\trecursive\x18\x02 \x01(\x08R\trecursive\x12#\n\rinclude_entry\x18\x03 \x01(\x08R\x0cincludeEntry\x120\n\x14allow_network_mounts\x18\x04 \x01(\x08R\x12allowNetworkMounts"6\n\x15CreateWatcherResponse\x12\x1d\n\nwatcher_id\x18\x01 \x01(\tR\twatcherId"8\n\x17GetWatcherEventsRequest\x12\x1d\n\nwatcher_id\x18\x01 \x01(\tR\twatcherId"O\n\x18GetWatcherEventsResponse\x123\n\x06events\x18\x01 \x03(\x0b2\x1b.filesystem.FilesystemEventR\x06events"5\n\x14RemoveWatcherRequest\x12\x1d\n\nwatcher_id\x18\x01 \x01(\tR\twatcherId"\x17\n\x15RemoveWatcherResponse*i\n\x08FileType\x12\x19\n\x15FILE_TYPE_UNSPECIFIED\x10\x00\x12\x12\n\x0eFILE_TYPE_FILE\x10\x01\x12\x17\n\x13FILE_TYPE_DIRECTORY\x10\x02\x12\x15\n\x11FILE_TYPE_SYMLINK\x10\x03*\x98\x01\n\tEventType\x12\x1a\n\x16EVENT_TYPE_UNSPECIFIED\x10\x00\x12\x15\n\x11EVENT_TYPE_CREATE\x10\x01\x12\x14\n\x10EVENT_TYPE_WRITE\x10\x02\x12\x15\n\x11EVENT_TYPE_REMOVE\x10\x03\x12\x15\n\x11EVENT_TYPE_RENAME\x10\x04\x12\x14\n\x10EVENT_TYPE_CHMOD\x10\x052\x9f\x05\n\nFilesystem\x129\n\x04Stat\x12\x17.filesystem.StatRequest\x1a\x18.filesystem.StatResponse\x12B\n\x07MakeDir\x12\x1a.filesystem.MakeDirRequest\x1a\x1b.filesystem.MakeDirResponse\x129\n\x04Move\x12\x17.filesystem.MoveRequest\x1a\x18.filesystem.MoveResponse\x12B\n\x07ListDir\x12\x1a.filesystem.ListDirRequest\x1a\x1b.filesystem.ListDirResponse\x12?\n\x06Remove\x12\x19.filesystem.RemoveRequest\x1a\x1a.filesystem.RemoveResponse\x12G\n\x08WatchDir\x12\x1b.filesystem.WatchDirRequest\x1a\x1c.filesystem.WatchDirResponse0\x01\x12T\n\rCreateWatcher\x12 .filesystem.CreateWatcherRequest\x1a!.filesystem.CreateWatcherResponse\x12]\n\x10GetWatcherEvents\x12#.filesystem.GetWatcherEventsRequest\x1a$.filesystem.GetWatcherEventsResponse\x12T\n\rRemoveWatcher\x12 .filesystem.RemoveWatcherRequest\x1a!.filesystem.RemoveWatcherResponseBi\n\x0ecom.filesystemB\x0fFilesystemProtoP\x01\xa2\x02\x03FXX\xaa\x02\nFilesystem\xca\x02\nFilesystem\xe2\x02\x16Filesystem\\GPBMetadata\xea\x02\nFilesystemb\x06proto3',
816
+ b'\n\x1bfilesystem/filesystem.proto\x12\nfilesystem\x1a\x1fgoogle/protobuf/timestamp.proto"G\n\x0bMoveRequest\x12\x16\n\x06source\x18\x01 \x01(\tR\x06source\x12 \n\x0bdestination\x18\x02 \x01(\tR\x0bdestination";\n\x0cMoveResponse\x12+\n\x05entry\x18\x01 \x01(\x0b2\x15.filesystem.EntryInfoR\x05entry"$\n\x0eMakeDirRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path">\n\x0fMakeDirResponse\x12+\n\x05entry\x18\x01 \x01(\x0b2\x15.filesystem.EntryInfoR\x05entry"#\n\rRemoveRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path"\x10\n\x0eRemoveResponse"!\n\x0bStatRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path";\n\x0cStatResponse\x12+\n\x05entry\x18\x01 \x01(\x0b2\x15.filesystem.EntryInfoR\x05entry"\xf0\x03\n\tEntryInfo\x12\x12\n\x04name\x18\x01 \x01(\tR\x04name\x12(\n\x04type\x18\x02 \x01(\x0e2\x14.filesystem.FileTypeR\x04type\x12\x12\n\x04path\x18\x03 \x01(\tR\x04path\x12\x12\n\x04size\x18\x04 \x01(\x03R\x04size\x12\x12\n\x04mode\x18\x05 \x01(\rR\x04mode\x12 \n\x0bpermissions\x18\x06 \x01(\tR\x0bpermissions\x12\x14\n\x05owner\x18\x07 \x01(\tR\x05owner\x12\x14\n\x05group\x18\x08 \x01(\tR\x05group\x12?\n\rmodified_time\x18\t \x01(\x0b2\x1a.google.protobuf.TimestampR\x0cmodifiedTime\x12*\n\x0esymlink_target\x18\n \x01(\tH\x00R\rsymlinkTarget\x88\x01\x01\x12?\n\x08metadata\x18\x0b \x03(\x0b2#.filesystem.EntryInfo.MetadataEntryR\x08metadata\x12\x1d\n\nis_symlink\x18\x0c \x01(\x08R\tisSymlink\x1a;\n\rMetadataEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n\x05value\x18\x02 \x01(\tR\x05value:\x028\x01B\x11\n\x0f_symlink_target":\n\x0eListDirRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12\x14\n\x05depth\x18\x02 \x01(\rR\x05depth"B\n\x0fListDirResponse\x12/\n\x07entries\x18\x01 \x03(\x0b2\x15.filesystem.EntryInfoR\x07entries"\x9a\x01\n\x0fWatchDirRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12\x1c\n\trecursive\x18\x02 \x01(\x08R\trecursive\x12#\n\rinclude_entry\x18\x03 \x01(\x08R\x0cincludeEntry\x120\n\x14allow_network_mounts\x18\x04 \x01(\x08R\x12allowNetworkMounts"\x8c\x01\n\x0fFilesystemEvent\x12\x12\n\x04name\x18\x01 \x01(\tR\x04name\x12)\n\x04type\x18\x02 \x01(\x0e2\x15.filesystem.EventTypeR\x04type\x120\n\x05entry\x18\x03 \x01(\x0b2\x15.filesystem.EntryInfoH\x00R\x05entry\x88\x01\x01B\x08\n\x06_entry"\xfe\x01\n\x10WatchDirResponse\x12?\n\x05start\x18\x01 \x01(\x0b2\'.filesystem.WatchDirResponse.StartEventH\x00R\x05start\x12=\n\nfilesystem\x18\x02 \x01(\x0b2\x1b.filesystem.FilesystemEventH\x00R\nfilesystem\x12F\n\tkeepalive\x18\x03 \x01(\x0b2&.filesystem.WatchDirResponse.KeepAliveH\x00R\tkeepalive\x1a\x0c\n\nStartEvent\x1a\x0b\n\tKeepAliveB\x07\n\x05event"\x9f\x01\n\x14CreateWatcherRequest\x12\x12\n\x04path\x18\x01 \x01(\tR\x04path\x12\x1c\n\trecursive\x18\x02 \x01(\x08R\trecursive\x12#\n\rinclude_entry\x18\x03 \x01(\x08R\x0cincludeEntry\x120\n\x14allow_network_mounts\x18\x04 \x01(\x08R\x12allowNetworkMounts"6\n\x15CreateWatcherResponse\x12\x1d\n\nwatcher_id\x18\x01 \x01(\tR\twatcherId"8\n\x17GetWatcherEventsRequest\x12\x1d\n\nwatcher_id\x18\x01 \x01(\tR\twatcherId"O\n\x18GetWatcherEventsResponse\x123\n\x06events\x18\x01 \x03(\x0b2\x1b.filesystem.FilesystemEventR\x06events"5\n\x14RemoveWatcherRequest\x12\x1d\n\nwatcher_id\x18\x01 \x01(\tR\twatcherId"\x17\n\x15RemoveWatcherResponse*i\n\x08FileType\x12\x19\n\x15FILE_TYPE_UNSPECIFIED\x10\x00\x12\x12\n\x0eFILE_TYPE_FILE\x10\x01\x12\x17\n\x13FILE_TYPE_DIRECTORY\x10\x02\x12\x15\n\x11FILE_TYPE_SYMLINK\x10\x03*\x98\x01\n\tEventType\x12\x1a\n\x16EVENT_TYPE_UNSPECIFIED\x10\x00\x12\x15\n\x11EVENT_TYPE_CREATE\x10\x01\x12\x14\n\x10EVENT_TYPE_WRITE\x10\x02\x12\x15\n\x11EVENT_TYPE_REMOVE\x10\x03\x12\x15\n\x11EVENT_TYPE_RENAME\x10\x04\x12\x14\n\x10EVENT_TYPE_CHMOD\x10\x052\x9f\x05\n\nFilesystem\x129\n\x04Stat\x12\x17.filesystem.StatRequest\x1a\x18.filesystem.StatResponse\x12B\n\x07MakeDir\x12\x1a.filesystem.MakeDirRequest\x1a\x1b.filesystem.MakeDirResponse\x129\n\x04Move\x12\x17.filesystem.MoveRequest\x1a\x18.filesystem.MoveResponse\x12B\n\x07ListDir\x12\x1a.filesystem.ListDirRequest\x1a\x1b.filesystem.ListDirResponse\x12?\n\x06Remove\x12\x19.filesystem.RemoveRequest\x1a\x1a.filesystem.RemoveResponse\x12G\n\x08WatchDir\x12\x1b.filesystem.WatchDirRequest\x1a\x1c.filesystem.WatchDirResponse0\x01\x12T\n\rCreateWatcher\x12 .filesystem.CreateWatcherRequest\x1a!.filesystem.CreateWatcherResponse\x12]\n\x10GetWatcherEvents\x12#.filesystem.GetWatcherEventsRequest\x1a$.filesystem.GetWatcherEventsResponse\x12T\n\rRemoveWatcher\x12 .filesystem.RemoveWatcherRequest\x1a!.filesystem.RemoveWatcherResponseBi\n\x0ecom.filesystemB\x0fFilesystemProtoP\x01\xa2\x02\x03FXX\xaa\x02\nFilesystem\xca\x02\nFilesystem\xe2\x02\x16Filesystem\\GPBMetadata\xea\x02\nFilesystemb\x06proto3',
809
817
  [
810
818
  timestamp_pb.desc(),
811
819
  ],
@@ -130,7 +130,9 @@ class EntryInfo(WriteInfo):
130
130
  def map_entry_info(entry: filesystem_pb.EntryInfo) -> EntryInfo:
131
131
  return EntryInfo(
132
132
  name=entry.name,
133
- type=map_file_type(entry.type),
133
+ # Newer envd reports a symlink's target type in `type` and marks the
134
+ # link itself with `is_symlink`; older envd reports SYMLINK in `type`.
135
+ type=FileType.SYMLINK if entry.is_symlink else map_file_type(entry.type),
134
136
  path=entry.path,
135
137
  size=entry.size,
136
138
  mode=entry.mode,
@@ -535,29 +535,73 @@ class SandboxNetworkInfo(TypedDict, total=False):
535
535
  https_ports: List[int]
536
536
 
537
537
 
538
+ SnapshotMode = Literal["full", "filesystem"]
539
+ """
540
+ What a pause or snapshot persists.
541
+
542
+ ``"full"`` persists the filesystem and the memory (running processes, in-memory
543
+ state and open connections); resuming restores the sandbox exactly where it left
544
+ off. ``"filesystem"`` persists only the filesystem: smaller and faster to take,
545
+ and resuming (or creating a sandbox from the snapshot) cold-boots it from disk,
546
+ without the running processes, in-memory state and open connections.
547
+ """
548
+
549
+
550
+ def resolve_snapshot_memory(
551
+ field: str,
552
+ mode: Optional[SnapshotMode],
553
+ keep_memory: Optional[bool] = None,
554
+ ) -> Union[Unset, bool]:
555
+ """Resolve ``mode`` (or the deprecated ``keep_memory``) into the API's
556
+ ``memory`` flag.
557
+
558
+ Unset, it stays ``UNSET`` so the API default (currently a full snapshot)
559
+ applies. ``field`` names the option in error messages.
560
+ """
561
+ if mode is not None and keep_memory is not None:
562
+ raise InvalidArgumentException(
563
+ f"Pass either {field} or the deprecated keep_memory, not both."
564
+ )
565
+ if mode is None:
566
+ return keep_memory if keep_memory is not None else UNSET
567
+ # Re-check at runtime for callers that bypass the type.
568
+ allowed = ("full", "filesystem")
569
+ if mode not in allowed:
570
+ raise InvalidArgumentException(
571
+ f"{field} must be one of: {', '.join(allowed)} (got {mode!r})."
572
+ )
573
+ return mode == "full"
574
+
575
+
538
576
  class SandboxOnTimeoutPause(TypedDict):
539
577
  """
540
578
  Object form of `on_timeout` that auto-pauses the sandbox when the timeout is
541
- reached, optionally controlling the pause snapshot kind via `keep_memory`.
579
+ reached, optionally controlling the pause snapshot kind via `mode`.
542
580
  """
543
581
 
544
582
  action: Literal["pause"]
545
583
  """Auto-pause the sandbox when the timeout is reached."""
546
584
 
547
- keep_memory: NotRequired[bool]
585
+ mode: NotRequired[SnapshotMode]
548
586
  """
549
- Whether the timeout auto-pause keeps a full memory snapshot. Left unset, it is
550
- omitted from the create request and the API's own default (currently enabled)
551
- applies. When `False`, the auto-pause drops the in-memory state and persists
552
- only the filesystem (a filesystem-only snapshot); resuming such a sandbox
553
- cold-boots (reboots) it from disk, losing running processes and open
554
- connections.
587
+ What the timeout auto-pause persists. Left unset, it is omitted from the
588
+ create request and the API's own default (currently `"full"`) applies. With
589
+ `"filesystem"`, the auto-pause drops the in-memory state and persists only
590
+ the filesystem; resuming such a sandbox cold-boots (reboots) it from disk,
591
+ losing running processes and open connections.
555
592
 
556
- Cannot be combined with `auto_resume`: auto-resume wakes a paused sandbox on
557
- inbound traffic by restoring its memory snapshot in place, so the request that
558
- woke it hits an already-running process. A filesystem-only snapshot has no
559
- memory to restore — resuming cold-boots it — so it can't be woken transparently
560
- by traffic and must be resumed explicitly via `connect()`.
593
+ `"filesystem"` cannot be combined with `auto_resume`: auto-resume wakes a
594
+ paused sandbox on inbound traffic by restoring its memory snapshot in place,
595
+ so the request that woke it hits an already-running process. A
596
+ filesystem-only snapshot has no memory to restore — resuming cold-boots it —
597
+ so it can't be woken transparently by traffic and must be resumed explicitly
598
+ via `connect()`.
599
+ """
600
+
601
+ keep_memory: NotRequired[bool]
602
+ """
603
+ :deprecated: Use `mode` instead: `keep_memory: False` is
604
+ `mode: "filesystem"`, `keep_memory: True` is `mode: "full"`.
561
605
  """
562
606
 
563
607
 
@@ -576,9 +620,8 @@ SandboxOnTimeout = Union[
576
620
  """
577
621
  What should happen to the sandbox when the timeout is reached. Either the bare
578
622
  action (`"pause"` / `"kill"`) or the object form. The object form is a
579
- discriminated union on `action`: `keep_memory` is only accepted alongside
580
- `action: "pause"`. Passing `keep_memory` with `action: "kill"` is a static type
581
- error.
623
+ discriminated union on `action`: `mode` is only accepted alongside
624
+ `action: "pause"`. Passing `mode` with `action: "kill"` is a static type error.
582
625
  """
583
626
 
584
627
 
@@ -593,7 +636,7 @@ class SandboxLifecycle(TypedDict):
593
636
  """
594
637
  What should happen to the sandbox when timeout is reached. `"kill"` terminates
595
638
  the sandbox; `"pause"` pauses it for later resume. Accepts either the bare
596
- action or an object `{"action": "pause", "keep_memory": ...}` /
639
+ action or an object `{"action": "pause", "mode": ...}` /
597
640
  `{"action": "kill"}` to also control the pause snapshot kind. A value outside
598
641
  the two actions raises `InvalidArgumentException`. Omitted from the
599
642
  create request when unset, leaving the API's default (currently `"kill"`) in
@@ -605,8 +648,8 @@ class SandboxLifecycle(TypedDict):
605
648
  Whether activity should cause the sandbox to resume when paused. Leave unset
606
649
  to let the API pick the behavior. Set `False` to opt out explicitly and keep
607
650
  auto-resume off even if the API's default changes. Can be `True` only when
608
- `on_timeout` is `pause`. Not supported when `keep_memory` is `False`
609
- (a filesystem-only snapshot must be resumed explicitly via `connect()`).
651
+ `on_timeout` is `pause`. Not supported with `mode: "filesystem"` (a
652
+ filesystem-only snapshot must be resumed explicitly via `connect()`).
610
653
  """
611
654
 
612
655
 
@@ -901,25 +944,23 @@ def build_lifecycle_config(
901
944
  ``auto_pause`` is left unset when no ``on_timeout`` was configured: sending
902
945
  ``False`` would be indistinguishable from an explicit ``"kill"`` and would
903
946
  override the default the API owns. ``auto_pause_memory`` is likewise left
904
- unset unless the caller chose ``keep_memory``.
947
+ unset unless the caller chose ``mode``.
905
948
  """
906
- # on_timeout accepts a bare action or {"action", "keep_memory"}; normalize.
907
- # Only the object form carries keep_memory.
949
+ # on_timeout accepts a bare action or {"action", "mode"}; normalize.
950
+ # Only the object form carries mode (or the deprecated keep_memory).
908
951
  on_timeout_raw = lifecycle.get("on_timeout") if lifecycle else None
909
952
  # A missing on_timeout — or an explicit None from an untyped caller — is not
910
953
  # a choice of kill. It only resolves to kill semantics locally, for the
911
- # validation below and for keep_memory.
954
+ # validation below.
912
955
  on_timeout_configured = on_timeout_raw is not None
913
956
  if isinstance(on_timeout_raw, dict):
914
957
  on_timeout = on_timeout_raw.get("action")
915
- keep_memory_provided = "keep_memory" in on_timeout_raw
916
- keep_memory = on_timeout_raw.get("keep_memory")
958
+ pause_opts = cast(Dict[str, Any], on_timeout_raw)
917
959
  else:
918
960
  # Only fall back when unconfigured, not on other falsy-but-present
919
961
  # values an untyped caller might pass.
920
962
  on_timeout = on_timeout_raw if on_timeout_configured else "kill"
921
- keep_memory = None
922
- keep_memory_provided = False
963
+ pause_opts = {}
923
964
 
924
965
  allowed_actions = ("pause", "kill")
925
966
  if on_timeout_configured and on_timeout not in allowed_actions:
@@ -935,19 +976,15 @@ def build_lifecycle_config(
935
976
  # auto_pause — so an unrecognized value cannot be rejected server-side, and
936
977
  # resolving it to kill would delete the sandbox a caller asked to preserve.
937
978
 
938
- # keep_memory only governs a pause action. The discriminated union type
939
- # forbids it on action="kill"; re-check at runtime for callers that
940
- # bypass the type.
941
- if keep_memory_provided and on_timeout != "pause":
979
+ # mode only governs a pause action. The discriminated union type forbids it
980
+ # on action="kill"; re-check at runtime for callers that bypass the type.
981
+ if ("mode" in pause_opts or "keep_memory" in pause_opts) and on_timeout != "pause":
942
982
  raise InvalidArgumentException(
943
- "keep_memory is only allowed when on_timeout action is 'pause'."
983
+ "mode is only allowed when on_timeout action is 'pause'."
944
984
  )
945
-
946
- # A missing or explicit None keep_memory defaults to True (full memory) for
947
- # local validation below. The wire field is omitted unless keep_memory was
948
- # actually provided.
949
- if keep_memory is None:
950
- keep_memory = True
985
+ memory = resolve_snapshot_memory(
986
+ 'on_timeout["mode"]', pause_opts.get("mode"), pause_opts.get("keep_memory")
987
+ )
951
988
  auto_resume = lifecycle.get("auto_resume") if lifecycle else None
952
989
 
953
990
  if auto_resume and on_timeout != "pause":
@@ -955,18 +992,16 @@ def build_lifecycle_config(
955
992
  "auto_resume can only be True when on_timeout action is 'pause'."
956
993
  )
957
994
 
958
- if not keep_memory and auto_resume:
995
+ if memory is False and auto_resume:
959
996
  raise InvalidArgumentException(
960
- "auto_resume: True is not a valid value when keep_memory: False - "
997
+ "auto_resume: True is not a valid value with mode: 'filesystem' - "
961
998
  "a filesystem-only snapshot cannot be auto-resumed by traffic and "
962
999
  "must be resumed explicitly using Sandbox.connect()."
963
1000
  )
964
1001
 
965
1002
  return SandboxLifecycleBody(
966
1003
  auto_pause=(on_timeout == "pause") if on_timeout_configured else UNSET,
967
- auto_pause_memory=(
968
- keep_memory if on_timeout == "pause" and keep_memory_provided else UNSET
969
- ),
1004
+ auto_pause_memory=memory if on_timeout == "pause" else UNSET,
970
1005
  auto_resume=(
971
1006
  ClientSandboxAutoResumeConfig(enabled=auto_resume)
972
1007
  if auto_resume is not None
@@ -156,17 +156,17 @@ class AsyncCommandHandle:
156
156
  match oneof:
157
157
  case Oneof(field="data", value=data):
158
158
  match data.output:
159
- case Oneof(field="stdout", value=chunk) if chunk:
159
+ case Oneof(field="stdout", value=chunk):
160
160
  out = self._stdout_decoder.decode(chunk)
161
161
  if out:
162
162
  self._stdout_chunks.append(out)
163
163
  yield out, None, None
164
- case Oneof(field="stderr", value=chunk) if chunk:
164
+ case Oneof(field="stderr", value=chunk):
165
165
  out = self._stderr_decoder.decode(chunk)
166
166
  if out:
167
167
  self._stderr_chunks.append(out)
168
168
  yield None, out, None
169
- case Oneof(field="pty", value=chunk) if chunk:
169
+ case Oneof(field="pty", value=chunk):
170
170
  yield None, None, chunk
171
171
  case Oneof(field="end", value=end):
172
172
  # Flush trailing decoder bytes into the accumulators and