withruntime 0.31.0__tar.gz → 0.31.1__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 (433) hide show
  1. {withruntime-0.31.0/withruntime.egg-info → withruntime-0.31.1}/PKG-INFO +2 -1
  2. {withruntime-0.31.0 → withruntime-0.31.1}/pyproject.toml +3 -2
  3. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_agents.py +6 -3
  4. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_answer_start.py +8 -2
  5. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_apps_builds.py +9 -4
  6. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_async_stream_cleanup.py +1 -1
  7. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_audit.py +1 -1
  8. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_billing.py +1 -1
  9. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_blaxel.py +8 -5
  10. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_ci.py +21 -1
  11. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_e2b_deadline.py +21 -12
  12. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_interpreter_deadline.py +1 -1
  13. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_customer_usage.py +4 -1
  14. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_download_labels.py +4 -1
  15. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_connection_cap.py +26 -12
  16. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_exec_stream.py +12 -7
  17. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_files_download.py +13 -1
  18. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_files_write_lost_body.py +4 -1
  19. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_http_tls_close.py +1 -1
  20. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_identity_token.py +1 -1
  21. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_images_v2.py +1 -1
  22. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_images_volumes_interpreter.py +1 -1
  23. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_interface_contract.py +1 -1
  24. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_jobs.py +1 -1
  25. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_lifecycle_settings.py +1 -1
  26. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_limits.py +1 -1
  27. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_modal_dropin.py +0 -9
  28. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_modal_examples.py +16 -3
  29. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_mounts.py +1 -1
  30. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_network_products.py +1 -1
  31. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_observability.py +1 -1
  32. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_package_typing.py +14 -1
  33. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_plans.py +1 -1
  34. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_previews_network_desktop.py +1 -1
  35. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_private_network.py +1 -1
  36. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_process_deadline.py +8 -4
  37. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_product_aliases.py +2 -1
  38. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_proxy.py +1 -1
  39. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_referrals.py +1 -1
  40. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_reservations.py +1 -1
  41. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_sandbox_sessions.py +1 -1
  42. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_secrets.py +3 -3
  43. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_signed_requests.py +1 -1
  44. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_snapshot_after_fork.py +1 -1
  45. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_switch_image.py +1 -1
  46. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_switching.py +1 -1
  47. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_tailscale.py +1 -1
  48. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_transport_body_recovery.py +34 -9
  49. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_transport_never_sent.py +1 -1
  50. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_volume_backups.py +1 -1
  51. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_wallet.py +1 -1
  52. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_watch.py +1 -1
  53. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/ci.py +39 -0
  54. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_http.py +16 -3
  55. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/ci.py +39 -0
  56. withruntime-0.31.1/withruntime/_version.py +1 -0
  57. {withruntime-0.31.0 → withruntime-0.31.1/withruntime.egg-info}/PKG-INFO +2 -1
  58. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime.egg-info/requires.txt +3 -0
  59. withruntime-0.31.0/withruntime/_version.py +0 -1
  60. {withruntime-0.31.0 → withruntime-0.31.1}/LICENSE +0 -0
  61. {withruntime-0.31.0 → withruntime-0.31.1}/README.md +0 -0
  62. {withruntime-0.31.0 → withruntime-0.31.1}/setup.cfg +0 -0
  63. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_account_errors.py +0 -0
  64. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_blaxel_0_4_17.py +0 -0
  65. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_blaxel_0_4_18.py +0 -0
  66. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_blaxel_create_timeout.py +0 -0
  67. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_blaxel_wait_deadline.py +0 -0
  68. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_browser.py +0 -0
  69. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_capacity_wait.py +0 -0
  70. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_live.py +0 -0
  71. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_modal_deadline_errors.py +0 -0
  72. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_new_providers.py +0 -0
  73. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_prime_contract.py +0 -0
  74. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_prime_process_lifecycle.py +0 -0
  75. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_prime_validation.py +0 -0
  76. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_disk_snapshots.py +0 -0
  77. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_e2b_pty.py +0 -0
  78. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_e2b_stream.py +0 -0
  79. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_e2b_watch.py +0 -0
  80. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_modal.py +0 -0
  81. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_morph.py +0 -0
  82. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_official.py +0 -0
  83. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_pins.py +0 -0
  84. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_processes.py +0 -0
  85. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_request_scope.py +0 -0
  86. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_runloop.py +0 -0
  87. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_shell.py +0 -0
  88. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_snapshot_capture.py +0 -0
  89. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_python_sprites.py +0 -0
  90. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_compat_router.py +0 -0
  91. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona.py +0 -0
  92. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_0_223_1.py +0 -0
  93. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_0_224_1.py +0 -0
  94. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_0_225_0.py +0 -0
  95. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_create_cleanup.py +0 -0
  96. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_create_options.py +0 -0
  97. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_daytona_refusals_lifted.py +0 -0
  98. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_deepagents.py +0 -0
  99. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_2_55.py +0 -0
  100. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_code_interpreter.py +0 -0
  101. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_exports.py +0 -0
  102. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_fork_validation.py +0 -0
  103. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_sandbox.py +0 -0
  104. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_upstream.py +0 -0
  105. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_e2b_watch.py +0 -0
  106. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_embed_and_webhook_watch.py +0 -0
  107. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_eval_sandbox.py +0 -0
  108. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_exec_stream_names.py +0 -0
  109. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_exec_user.py +0 -0
  110. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_file_archives.py +0 -0
  111. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_files_mode.py +0 -0
  112. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_files_upload_parallel.py +0 -0
  113. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_harbor.py +0 -0
  114. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_image_delete_by_name.py +0 -0
  115. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_inspect_ai.py +0 -0
  116. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_late_answer.py +0 -0
  117. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_machine_engine.py +0 -0
  118. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_modal_1_6_2.py +0 -0
  119. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_network_funding.py +0 -0
  120. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_openai_agents.py +0 -0
  121. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_out_of_memory.py +0 -0
  122. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_prime_0_4_5.py +0 -0
  123. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_prime_0_4_6.py +0 -0
  124. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_prime_0_4_7.py +0 -0
  125. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_process_input.py +0 -0
  126. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_process_object.py +0 -0
  127. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_process_output.py +0 -0
  128. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_process_write_backpressure.py +0 -0
  129. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_replayed_create_message.py +0 -0
  130. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_runloop_stream_cleanup.py +0 -0
  131. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_runloop_v2.py +0 -0
  132. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_sandbox_origin.py +0 -0
  133. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_sandboxes_delete_all.py +0 -0
  134. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_sandboxes_stop_all.py +0 -0
  135. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_saved_connection.py +0 -0
  136. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_snapshot_recovery.py +0 -0
  137. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_sso.py +0 -0
  138. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_start_report_kept.py +0 -0
  139. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_stream_cut_short.py +0 -0
  140. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_stream_exit_close.py +0 -0
  141. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_tools.py +0 -0
  142. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_trace_files.py +0 -0
  143. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_transport_connection_limits.py +0 -0
  144. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_unpack.py +0 -0
  145. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_upload_deadline.py +0 -0
  146. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_vercel.py +0 -0
  147. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_vercel_create_validation.py +0 -0
  148. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_vercel_disk_snapshot.py +0 -0
  149. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_vercel_refusals_lifted.py +0 -0
  150. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_volume_operations.py +0 -0
  151. {withruntime-0.31.0 → withruntime-0.31.1}/tests/test_wake_awake.py +0 -0
  152. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/__init__.py +0 -0
  153. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_agent_templates.py +0 -0
  154. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_api_defaults.py +0 -0
  155. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_client.py +0 -0
  156. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/__init__.py +0 -0
  157. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/agents.py +0 -0
  158. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/apps.py +0 -0
  159. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/audit.py +0 -0
  160. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/billing.py +0 -0
  161. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/browser.py +0 -0
  162. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/builds.py +0 -0
  163. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/containers.py +0 -0
  164. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/desktop.py +0 -0
  165. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/images.py +0 -0
  166. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/interpreter.py +0 -0
  167. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/jobs.py +0 -0
  168. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/limits.py +0 -0
  169. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/mcp.py +0 -0
  170. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/mounts.py +0 -0
  171. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/network.py +0 -0
  172. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/network_products.py +0 -0
  173. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/observability.py +0 -0
  174. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/plans.py +0 -0
  175. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/previews.py +0 -0
  176. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/private_network.py +0 -0
  177. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/referrals.py +0 -0
  178. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/reservations.py +0 -0
  179. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/secrets.py +0 -0
  180. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/signed_requests.py +0 -0
  181. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/sso.py +0 -0
  182. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/switching.py +0 -0
  183. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/tailscale.py +0 -0
  184. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/volumes.py +0 -0
  185. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_async_products/watch.py +0 -0
  186. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_clock.py +0 -0
  187. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_compat.py +0 -0
  188. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_compat_lease.py +0 -0
  189. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_compat_lifecycle.py +0 -0
  190. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_compat_shell.py +0 -0
  191. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_connection.py +0 -0
  192. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_errors.py +0 -0
  193. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_eval_sandbox.py +0 -0
  194. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_proxy.py +0 -0
  195. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_renamed.py +0 -0
  196. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_request_scope.py +0 -0
  197. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_client.py +0 -0
  198. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/__init__.py +0 -0
  199. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/agents.py +0 -0
  200. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/apps.py +0 -0
  201. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/audit.py +0 -0
  202. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/billing.py +0 -0
  203. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/browser.py +0 -0
  204. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/builds.py +0 -0
  205. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/containers.py +0 -0
  206. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/desktop.py +0 -0
  207. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/images.py +0 -0
  208. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/interpreter.py +0 -0
  209. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/jobs.py +0 -0
  210. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/limits.py +0 -0
  211. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/mcp.py +0 -0
  212. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/mounts.py +0 -0
  213. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/network.py +0 -0
  214. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/network_products.py +0 -0
  215. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/observability.py +0 -0
  216. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/plans.py +0 -0
  217. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/previews.py +0 -0
  218. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/private_network.py +0 -0
  219. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/referrals.py +0 -0
  220. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/reservations.py +0 -0
  221. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/secrets.py +0 -0
  222. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/signed_requests.py +0 -0
  223. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/sso.py +0 -0
  224. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/switching.py +0 -0
  225. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/tailscale.py +0 -0
  226. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/volumes.py +0 -0
  227. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_sync_products/watch.py +0 -0
  228. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_tunnel.py +0 -0
  229. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_unpack.py +0 -0
  230. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/_ws.py +0 -0
  231. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/__init__.py +0 -0
  232. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/_async_io.py +0 -0
  233. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/_async_sandbox.py +0 -0
  234. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/_core.py +0 -0
  235. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/_sync_io.py +0 -0
  236. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/_sync_sandbox.py +0 -0
  237. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/__init__.py +0 -0
  238. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/agents.py +0 -0
  239. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/__init__.py +0 -0
  240. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/__init__.py +0 -0
  241. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/applications/__init__.py +0 -0
  242. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/applications/list_application_revisions.py +0 -0
  243. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/compute/__init__.py +0 -0
  244. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/compute/get_sandbox.py +0 -0
  245. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/compute/update_sandbox.py +0 -0
  246. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/functions/__init__.py +0 -0
  247. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/functions/create_function.py +0 -0
  248. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/images.py +0 -0
  249. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/api/workspaces.py +0 -0
  250. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/client.py +0 -0
  251. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/__init__.py +0 -0
  252. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/create_job_execution_request.py +0 -0
  253. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/create_job_execution_request_env.py +0 -0
  254. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/env.py +0 -0
  255. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/function.py +0 -0
  256. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/function_runtime.py +0 -0
  257. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/function_spec.py +0 -0
  258. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/metadata.py +0 -0
  259. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/pagination_meta.py +0 -0
  260. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/models/workspace.py +0 -0
  261. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/pagination.py +0 -0
  262. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/client/types.py +0 -0
  263. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/common.py +0 -0
  264. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/drive.py +0 -0
  265. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/errors.py +0 -0
  266. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/jobs.py +0 -0
  267. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/sandbox/__init__.py +0 -0
  268. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/sandbox/types.py +0 -0
  269. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/core/secret.py +0 -0
  270. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/crewai.py +0 -0
  271. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/googleadk.py +0 -0
  272. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/langgraph.py +0 -0
  273. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/livekit.py +0 -0
  274. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/llamaindex.py +0 -0
  275. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/openai.py +0 -0
  276. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/pydantic.py +0 -0
  277. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/blaxel/telemetry.py +0 -0
  278. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/daytona/__init__.py +0 -0
  279. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/daytona/_async_daytona.py +0 -0
  280. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/daytona/_async_io.py +0 -0
  281. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/daytona/_core.py +0 -0
  282. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/daytona/_sync_daytona.py +0 -0
  283. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/daytona/_sync_io.py +0 -0
  284. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/deepagents.py +0 -0
  285. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/__init__.py +0 -0
  286. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/_async_io.py +0 -0
  287. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/_async_sandbox.py +0 -0
  288. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/_core.py +0 -0
  289. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/_sync_io.py +0 -0
  290. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/_sync_sandbox.py +0 -0
  291. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/__init__.py +0 -0
  292. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/_async_ci.py +0 -0
  293. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/_models.py +0 -0
  294. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/_sync_ci.py +0 -0
  295. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/charts.py +0 -0
  296. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/code_interpreter_async.py +0 -0
  297. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/code_interpreter_sync.py +0 -0
  298. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/code_interpreter/models.py +0 -0
  299. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/connection_config.py +0 -0
  300. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/exceptions.py +0 -0
  301. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/__init__.py +0 -0
  302. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/commands/__init__.py +0 -0
  303. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/commands/command_handle.py +0 -0
  304. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/commands/main.py +0 -0
  305. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/filesystem/__init__.py +0 -0
  306. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/filesystem/filesystem.py +0 -0
  307. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/filesystem/watch_handle.py +0 -0
  308. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/network.py +0 -0
  309. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/sandbox_api.py +0 -0
  310. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox/signature.py +0 -0
  311. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/__init__.py +0 -0
  312. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/commands/__init__.py +0 -0
  313. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/commands/command.py +0 -0
  314. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/commands/command_handle.py +0 -0
  315. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/commands/pty.py +0 -0
  316. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/filesystem/__init__.py +0 -0
  317. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/filesystem/filesystem.py +0 -0
  318. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/filesystem/watch_handle.py +0 -0
  319. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/main.py +0 -0
  320. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/paginator.py +0 -0
  321. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_async/utils.py +0 -0
  322. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/__init__.py +0 -0
  323. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/commands/__init__.py +0 -0
  324. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/commands/command.py +0 -0
  325. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/commands/command_handle.py +0 -0
  326. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/commands/pty.py +0 -0
  327. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/filesystem/__init__.py +0 -0
  328. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/filesystem/filesystem.py +0 -0
  329. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/filesystem/watch_handle.py +0 -0
  330. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/git.py +0 -0
  331. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/main.py +0 -0
  332. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/sandbox_sync/paginator.py +0 -0
  333. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/secret/__init__.py +0 -0
  334. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template/__init__.py +0 -0
  335. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template/dockerfile_parser.py +0 -0
  336. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template/logger.py +0 -0
  337. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template/main.py +0 -0
  338. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template/readycmd.py +0 -0
  339. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template/types.py +0 -0
  340. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template_async/__init__.py +0 -0
  341. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template_async/main.py +0 -0
  342. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template_sync/__init__.py +0 -0
  343. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/template_sync/main.py +0 -0
  344. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/volume/__init__.py +0 -0
  345. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/volume/connection_config.py +0 -0
  346. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/volume/types.py +0 -0
  347. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/volume/volume_async.py +0 -0
  348. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/e2b/volume/volume_sync.py +0 -0
  349. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/harbor.py +0 -0
  350. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/inspect_ai.py +0 -0
  351. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/__init__.py +0 -0
  352. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_async.py +0 -0
  353. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_dual.py +0 -0
  354. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_fs_async.py +0 -0
  355. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_fs_common.py +0 -0
  356. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_fs_sync.py +0 -0
  357. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_lookup.py +0 -0
  358. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_object.py +0 -0
  359. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_probe.py +0 -0
  360. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_snapshot.py +0 -0
  361. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/_tunnel.py +0 -0
  362. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/app.py +0 -0
  363. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/cloud_bucket_mount.py +0 -0
  364. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/container_process.py +0 -0
  365. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/exception.py +0 -0
  366. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/file_pattern_matcher.py +0 -0
  367. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/image.py +0 -0
  368. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/io_streams.py +0 -0
  369. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/output.py +0 -0
  370. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/proxy.py +0 -0
  371. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/sandbox/__init__.py +0 -0
  372. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/sandbox/sandbox.py +0 -0
  373. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/sandbox_fs.py +0 -0
  374. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/secret.py +0 -0
  375. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/snapshot.py +0 -0
  376. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/stream_type.py +0 -0
  377. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/types.py +0 -0
  378. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/modal/volume.py +0 -0
  379. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/morph/__init__.py +0 -0
  380. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/morph/api.py +0 -0
  381. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/openai_agents.py +0 -0
  382. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/__init__.py +0 -0
  383. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/_async.py +0 -0
  384. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/_sync.py +0 -0
  385. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/core/__init__.py +0 -0
  386. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/core/client.py +0 -0
  387. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/exceptions.py +0 -0
  388. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/models.py +0 -0
  389. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/process.py +0 -0
  390. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/prime/sandbox.py +0 -0
  391. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/py.typed +0 -0
  392. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/__init__.py +0 -0
  393. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/_async.py +0 -0
  394. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/_exceptions.py +0 -0
  395. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/_snapshots.py +0 -0
  396. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/_sync.py +0 -0
  397. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/_v2.py +0 -0
  398. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/lib/__init__.py +0 -0
  399. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/lib/polling.py +0 -0
  400. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/runloop/sdk/__init__.py +0 -0
  401. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/__init__.py +0 -0
  402. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_capture.py +0 -0
  403. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_capture_async.py +0 -0
  404. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_features.py +0 -0
  405. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_metadata.py +0 -0
  406. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_stream.py +0 -0
  407. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_stream_async.py +0 -0
  408. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/_translate.py +0 -0
  409. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/async_client.py +0 -0
  410. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/async_exec.py +0 -0
  411. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/client.py +0 -0
  412. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/control.py +0 -0
  413. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/exceptions.py +0 -0
  414. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/exec.py +0 -0
  415. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/filesystem.py +0 -0
  416. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/sprite.py +0 -0
  417. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/sprites/types.py +0 -0
  418. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/tools.py +0 -0
  419. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/__init__.py +0 -0
  420. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/_async_io.py +0 -0
  421. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/_async_sandbox.py +0 -0
  422. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/_core.py +0 -0
  423. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/_sync_io.py +0 -0
  424. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/_sync_sandbox.py +0 -0
  425. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/api.py +0 -0
  426. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/sandbox/__init__.py +0 -0
  427. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/vercel/sandbox/sync.py +0 -0
  428. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/wallet.py +0 -0
  429. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime/webhooks.py +0 -0
  430. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime.egg-info/SOURCES.txt +0 -0
  431. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime.egg-info/dependency_links.txt +0 -0
  432. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime.egg-info/entry_points.txt +0 -0
  433. {withruntime-0.31.0 → withruntime-0.31.1}/withruntime.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: withruntime
3
- Version: 0.31.0
3
+ Version: 0.31.1
4
4
  Summary: Runtime Cloud: one client (sync and async) for every Runtime product. Sandboxes first.
5
5
  License: Apache-2.0
6
6
  Project-URL: Homepage, https://withruntime.com
@@ -11,6 +11,7 @@ Keywords: sandbox,ai-agents,agents,microvm,firecracker,code-execution,code-inter
11
11
  Requires-Python: >=3.9
12
12
  Description-Content-Type: text/markdown
13
13
  License-File: LICENSE
14
+ Requires-Dist: tomli>=1.1.0; python_version < "3.11"
14
15
  Provides-Extra: e2b
15
16
  Requires-Dist: httpx<1.0.0,>=0.27.0; extra == "e2b"
16
17
  Provides-Extra: openai-agents
@@ -4,12 +4,13 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "withruntime"
7
- version = "0.31.0"
7
+ version = "0.31.1"
8
8
  description = "Runtime Cloud: one client (sync and async) for every Runtime product. Sandboxes first."
9
9
  readme = "README.md"
10
10
  license = { text = "Apache-2.0" }
11
11
  requires-python = ">=3.9"
12
- dependencies = []
12
+ # withruntime.modal's Image.uv_sync and poetry_install read pyproject.toml; tomllib is 3.11+.
13
+ dependencies = ['tomli>=1.1.0; python_version < "3.11"']
13
14
  keywords = ["sandbox", "ai-agents", "agents", "microvm", "firecracker", "code-execution", "code-interpreter", "mcp", "llm"]
14
15
 
15
16
  [project.urls]
@@ -13,6 +13,7 @@ from urllib.parse import parse_qs, urlsplit
13
13
  from withruntime import (AsyncRuntime, AuthenticationError, ConflictError, InvalidRequestError, NotFoundError,
14
14
  PermissionDeniedError, RateLimitError, Runtime)
15
15
  from withruntime import RuntimeError as RuntimeAPIError
16
+ from tests.instant_sleeps import instant_sleeps
16
17
 
17
18
  AGENT_ID = "11111111-1111-4111-8111-111111111111"
18
19
  SESSION_ID = "22222222-2222-4222-8222-222222222222"
@@ -316,7 +317,7 @@ class AgentsTest(unittest.TestCase):
316
317
  with self.client() as runtime:
317
318
  handle = runtime.agents.sessions.get(SESSION_ID)
318
319
  with self.assertRaises(RuntimeAPIError) as caught:
319
- handle.wait(timeout=0.3)
320
+ handle.wait(timeout=0.05)
320
321
  self.assertEqual(caught.exception.code, "timeout")
321
322
  with self.assertRaises(InvalidRequestError):
322
323
  handle.wait(timeout=-1)
@@ -372,12 +373,14 @@ class AgentsTest(unittest.TestCase):
372
373
  def test_refusals_are_the_sdks_own_errors(self):
373
374
  for mode, (status, code, kind) in REFUSALS.items():
374
375
  Stub.seen, Stub.mode = [], mode
375
- with self.client() as runtime:
376
+ with self.client() as runtime, instant_sleeps() as slept:
376
377
  with self.assertRaises(kind) as caught:
377
378
  runtime.agents.start("dev", "hi")
378
379
  self.assertEqual((caught.exception.code, caught.exception.status), (code, status))
379
- # A 429 is retried as every product's is (with the same key); the rest are refused once.
380
+ # A 429 is retried as every product's is (with the same key), after
381
+ # its back-offs; the rest are refused once.
380
382
  self.assertEqual(len(Stub.seen), 3 if status == 429 else 1, mode)
383
+ self.assertEqual(len(slept), 2 if status == 429 else 0, mode)
381
384
 
382
385
  def test_templates_are_the_guides_and_merge_a_use_over_a_harness(self):
383
386
  with self.client() as runtime:
@@ -10,6 +10,7 @@ from http.server import BaseHTTPRequestHandler, ThreadingHTTPServer
10
10
  from unittest import mock
11
11
 
12
12
  from withruntime import AsyncRuntime, Runtime
13
+ from tests.instant_sleeps import instant_sleeps
13
14
 
14
15
 
15
16
  class SilentFirst:
@@ -21,6 +22,9 @@ class SilentFirst:
21
22
 
22
23
  class Handler(BaseHTTPRequestHandler):
23
24
  protocol_version = "HTTP/1.1"
25
+ # A header and its body, written apart, each go at once: with Nagle a
26
+ # kept-alive answer waited 40 ms on the client's delayed ACK.
27
+ disable_nagle_algorithm = True
24
28
 
25
29
  def log_message(self, *_):
26
30
  pass
@@ -39,7 +43,7 @@ class SilentFirst:
39
43
  self.wfile.write(body)
40
44
 
41
45
  self.server = ThreadingHTTPServer(("127.0.0.1", 0), Handler)
42
- self.thread = threading.Thread(target=self.server.serve_forever, daemon=True)
46
+ self.thread = threading.Thread(target=self.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True)
43
47
  self.thread.start()
44
48
  self.url = f"http://127.0.0.1:{self.server.server_address[1]}"
45
49
 
@@ -57,7 +61,8 @@ class AnswerStart(unittest.TestCase):
57
61
  world = SilentFirst()
58
62
  try:
59
63
  started = time.monotonic()
60
- with mock.patch("withruntime._http.ANSWER_START_SECONDS", 0.3, create=True):
64
+ with mock.patch("withruntime._http.ANSWER_START_SECONDS", 0.1, create=True), \
65
+ instant_sleeps() as slept:
61
66
  if asynchronous:
62
67
  async def run():
63
68
  async with AsyncRuntime(api_key="rk_test", base_url=world.url) as rt:
@@ -70,6 +75,7 @@ class AnswerStart(unittest.TestCase):
70
75
  self.assertEqual(len(world.keys), 2)
71
76
  self.assertTrue(world.keys[0])
72
77
  self.assertEqual(world.keys[0], world.keys[1])
78
+ self.assertEqual(len(slept), 1)
73
79
  self.assertLess(time.monotonic() - started, 5)
74
80
  finally:
75
81
  world.close()
@@ -11,6 +11,7 @@ from urllib.parse import parse_qs, urlsplit
11
11
 
12
12
  from withruntime import AsyncRuntime, InvalidRequestError, PermissionDeniedError, Runtime
13
13
  from withruntime import RuntimeError as RuntimeAPIError
14
+ from tests.instant_sleeps import instant_sleeps
14
15
 
15
16
  APP_ID = "11111111-1111-4111-8111-111111111111"
16
17
  DEPLOY_ID = "22222222-2222-4222-8222-222222222222"
@@ -115,7 +116,7 @@ class AppsBuildsTest(unittest.TestCase):
115
116
  @classmethod
116
117
  def setUpClass(cls):
117
118
  cls.server = ThreadingHTTPServer(("127.0.0.1", 0), Stub)
118
- threading.Thread(target=cls.server.serve_forever, daemon=True).start()
119
+ threading.Thread(target=cls.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True).start()
119
120
  cls.url = f"http://127.0.0.1:{cls.server.server_address[1]}"
120
121
 
121
122
  @classmethod
@@ -220,7 +221,7 @@ class AppsBuildsTest(unittest.TestCase):
220
221
  Stub.deploys = ["warming"]
221
222
  with self.client() as runtime:
222
223
  with self.assertRaises(RuntimeAPIError) as caught:
223
- runtime.apps.deploy(APP_ID, image="web", wait=True, timeout=0.3, poll=0.05,
224
+ runtime.apps.deploy(APP_ID, image="web", wait=True, timeout=0.1, poll=0.02,
224
225
  idempotency_key="deploy-2")
225
226
  self.assertEqual(caught.exception.code, "timeout")
226
227
  self.assertEqual(caught.exception.idempotency_key, "deploy-2")
@@ -338,9 +339,11 @@ class AppsBuildsTest(unittest.TestCase):
338
339
 
339
340
  def test_a_follow_whose_stream_keeps_ending_says_where_to_resume(self):
340
341
  Stub.follows = [[line("c1", "one")], [], [], []]
341
- with self.client() as runtime:
342
+ with self.client() as runtime, instant_sleeps() as slept:
342
343
  with self.assertRaises(RuntimeAPIError) as caught:
343
344
  list(runtime.builds.logs(BUILD_ID, follow=True))
345
+ # Each try again after its pause, recorded, not slept.
346
+ self.assertEqual(len(slept), 3)
344
347
  self.assertEqual((caught.exception.code, caught.exception.details), ("build_log_interrupted", {"cursor": "c1"}))
345
348
 
346
349
  def test_an_app_log_follow_resumes_on_continue_with_its_filters_and_gives_each_line_once(self):
@@ -366,9 +369,11 @@ class AppsBuildsTest(unittest.TestCase):
366
369
 
367
370
  def test_an_app_log_follow_retries_a_dropped_stream_three_times_then_says_where_to_resume(self):
368
371
  Stub.follows = [[app_line("c1", "one")], [], [], []]
369
- with self.client() as runtime:
372
+ with self.client() as runtime, instant_sleeps() as slept:
370
373
  with self.assertRaises(RuntimeAPIError) as caught:
371
374
  list(runtime.functions.logs(APP_ID, follow=True))
375
+ # Each try again after its pause, recorded, not slept.
376
+ self.assertEqual(len(slept), 3)
372
377
  self.assertEqual((caught.exception.code, caught.exception.details), ("app_log_interrupted", {"cursor": "c1"}))
373
378
  self.assertEqual([s[2] for s in Stub.seen],
374
379
  [{"follow": ["true"]}] + [{"follow": ["true"], "cursor": ["c1"]}] * 3)
@@ -231,7 +231,7 @@ class SyncStreamCleanupTest(unittest.TestCase):
231
231
  eof.set()
232
232
 
233
233
  self.server = ThreadingHTTPServer(('127.0.0.1', 0), Handler)
234
- self.thread = threading.Thread(target=self.server.serve_forever)
234
+ self.thread = threading.Thread(target=self.server.serve_forever, kwargs={"poll_interval": 0.01})
235
235
  self.thread.start()
236
236
  self.transport = SyncTransport('fixture', f'http://127.0.0.1:{self.server.server_port}', 5, 0)
237
237
 
@@ -41,7 +41,7 @@ class AuditTest(unittest.TestCase):
41
41
  @classmethod
42
42
  def setUpClass(cls):
43
43
  cls.server = ThreadingHTTPServer(("127.0.0.1", 0), Stub)
44
- threading.Thread(target=cls.server.serve_forever, daemon=True).start()
44
+ threading.Thread(target=cls.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True).start()
45
45
  cls.url = f"http://127.0.0.1:{cls.server.server_address[1]}"
46
46
 
47
47
  @classmethod
@@ -46,7 +46,7 @@ class BillingTest(unittest.TestCase):
46
46
  @classmethod
47
47
  def setUpClass(cls):
48
48
  cls.server = ThreadingHTTPServer(("127.0.0.1", 0), Stub)
49
- threading.Thread(target=cls.server.serve_forever, daemon=True).start()
49
+ threading.Thread(target=cls.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True).start()
50
50
  cls.url = f"http://127.0.0.1:{cls.server.server_address[1]}"
51
51
 
52
52
  @classmethod
@@ -8,6 +8,7 @@ import sys
8
8
  import tempfile
9
9
  import time
10
10
  import unittest
11
+ from unittest.mock import patch
11
12
  from datetime import datetime, timedelta, timezone
12
13
  from pathlib import Path
13
14
 
@@ -437,12 +438,12 @@ class ProcessLines(unittest.TestCase):
437
438
  table = Path(directory, "tcp")
438
439
  table.write_text(head + row + "\n")
439
440
  missing = str(Path(directory, "tcp6")) # a guest without IPv6
440
- result = subprocess.run(["bash", "-c", core.port_wait_script([3000], 1, (str(table), missing))[-1]],
441
+ result = subprocess.run(["bash", "-c", core.port_wait_script([3000], 0, (str(table), missing))[-1]],
441
442
  capture_output=True, timeout=10)
442
443
  self.assertEqual(result.returncode == 0, ready, row)
443
444
  with tempfile.TemporaryDirectory() as directory:
444
445
  both = (str(Path(directory, "tcp")), str(Path(directory, "tcp6")))
445
- result = subprocess.run(["bash", "-c", core.port_wait_script([3000], 1, both)[-1]], capture_output=True,
446
+ result = subprocess.run(["bash", "-c", core.port_wait_script([3000], 0, both)[-1]], capture_output=True,
446
447
  timeout=10)
447
448
  self.assertEqual(result.returncode, 1)
448
449
 
@@ -515,10 +516,12 @@ class Processes(Base):
515
516
  def test_a_wait_past_timeout_raises_and_leaves_it_running(self):
516
517
  self.keep_running()
517
518
  box = self.create()
518
- started = time.monotonic()
519
- with self.assertRaises(ResponseError) as caught:
519
+ # The deadline on the world's clock, which an output read moves by the
520
+ # wait it asks the server for: the second passes in one read, unslept.
521
+ with patch("withruntime.blaxel._sync_sandbox.now", lambda: self.world.waited), \
522
+ self.assertRaises(ResponseError) as caught:
520
523
  box.process.exec({"command": "sleep 99", "name": "slow", "wait_for_completion": True, "timeout": 1})
521
- self.assertLess(time.monotonic() - started, 5)
524
+ self.assertEqual(self.world.waited, 1)
522
525
  self.assertEqual(caught.exception.status_code, 422)
523
526
  self.assertEqual(str(caught.exception), "Sandbox request failed with status 422: process timed out after 1 seconds")
524
527
  self.assertEqual(self.world.called("request")[-1][0], "GET")
@@ -54,6 +54,10 @@ class Stub(BaseHTTPRequestHandler):
54
54
  if path == "/v1/ci/flakes" and self.command == "GET":
55
55
  return self.answer({"data": [{"id": "f1", "file": "t/a.test.ts", "state": "quarantined"}],
56
56
  "nextCursor": None})
57
+ if path == "/v1/ci/releases" and self.command == "GET":
58
+ return self.answer({"data": [{"id": 7, "commit": "a6049bf5a", "source": "hostd", "host": "web-4",
59
+ "line": "web-4: 562211980 -> a6049bf5a", "at": 1}],
60
+ "nextCursor": None})
57
61
  if path == "/v1/ci/flakes/f1":
58
62
  return self.answer({"id": "f1", "runs": [], "failures": []})
59
63
  if path == "/v1/ci/flakes/f1:update":
@@ -73,7 +77,7 @@ class CiTest(unittest.TestCase):
73
77
  @classmethod
74
78
  def setUpClass(cls):
75
79
  cls.server = ThreadingHTTPServer(("127.0.0.1", 0), Stub)
76
- threading.Thread(target=cls.server.serve_forever, daemon=True).start()
80
+ threading.Thread(target=cls.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True).start()
77
81
  cls.url = f"http://127.0.0.1:{cls.server.server_address[1]}"
78
82
 
79
83
  @classmethod
@@ -102,6 +106,13 @@ class CiTest(unittest.TestCase):
102
106
  self.assertEqual(Stub.seen[2][3], {"owner": "acme/testers", "prove": True})
103
107
  self.assertEqual(Stub.seen[3][3], {"deleteReason": "it timed a timer"})
104
108
 
109
+ def test_a_releases_steps_are_read_by_its_commit(self):
110
+ with self.client() as runtime:
111
+ steps = runtime.ci.releases.list(repository_id=REPO_ID, commit="a6049bf5a")
112
+ self.assertEqual(steps.data[0]["host"], "web-4")
113
+ self.assertEqual(Stub.seen[0][:3], ("GET", "/v1/ci/releases",
114
+ {"repositoryId": [REPO_ID], "commit": ["a6049bf5a"]}))
115
+
105
116
  def test_every_verb_calls_its_route_with_the_apis_names(self):
106
117
  with self.client() as runtime:
107
118
  connected = runtime.ci.repositories.connect(
@@ -137,6 +148,15 @@ class CiTest(unittest.TestCase):
137
148
  "limit": ["5"]})
138
149
  self.assertEqual(Stub.seen[6][2], {"repositoryId": [REPO_ID], "quarantined": ["true"], "limit": ["10"]})
139
150
 
151
+ def test_set_undo_turns_a_repositorys_undo_on_and_off(self):
152
+ with self.client() as runtime:
153
+ runtime.ci.repositories.set_undo(REPO_ID, True, idempotency_key="undo-1")
154
+ runtime.ci.repositories.set_undo(REPO_ID, False)
155
+ self.assertEqual([(s[0], s[1], s[3]) for s in Stub.seen], [
156
+ ("POST", f"/v1/ci/repositories/{REPO_ID}:update", {"undoCulprits": True}),
157
+ ("POST", f"/v1/ci/repositories/{REPO_ID}:update", {"undoCulprits": False})])
158
+ self.assertEqual(Stub.seen[0][4], "undo-1")
159
+
140
160
  def test_a_connect_with_only_a_repository_sends_only_it(self):
141
161
  with self.client() as runtime:
142
162
  runtime.ci.repositories.connect("acme/web")
@@ -3,12 +3,13 @@
3
3
  The local peer retains process output independently of a subscription. A client
4
4
  timeout may close the socket, but must never send a process signal.
5
5
 
6
- The client's deadline is half a second and the child runs for a second and a
7
- half, so the request reaches the peer and the deadline ends while the child
8
- runs, even on a loaded machine.
9
- With 30 ms against 0.4 s, a full check on 3 October 2026 (load 24) timed out
10
- before the peer's thread had started the child, and the test read a child that
11
- did not exist yet.
6
+ The child runs until the test releases it (closes its stdin), so the deadline
7
+ ends while it runs by construction, not by a race between two sleeps: a child
8
+ of a second and a half cost each test that much (23 October 2026). The
9
+ client's deadline is a quarter second, room for the request to reach the peer
10
+ and the peer to start the child on a loaded machine: with 30 ms, a full check
11
+ on 3 October 2026 (load 24) timed out before the peer's thread had started the
12
+ child, and the test read a child that did not exist yet.
12
13
  """
13
14
  import asyncio
14
15
  import json
@@ -20,9 +21,8 @@ import time
20
21
  from types import SimpleNamespace
21
22
  import unittest
22
23
 
23
- # The client's deadline, and how long the child runs: far apart on purpose.
24
- DEADLINE_S = 0.5
25
- CHILD_S = 1.5
24
+ # The client's deadline; the child outlives it until released.
25
+ DEADLINE_S = 0.25
26
26
 
27
27
  from withruntime._sync_client import _Transport, Process, Sandbox
28
28
  from withruntime._async_client import _Transport as AsyncTransport, AsyncProcess, AsyncSandbox
@@ -95,6 +95,7 @@ class Deadline(unittest.TestCase):
95
95
 
96
96
  def tearDown(self):
97
97
  if self.job is not None:
98
+ self.release_child()
98
99
  if not self.completed.wait(5):
99
100
  self.job.kill()
100
101
  self.collector.join(5)
@@ -103,16 +104,21 @@ class Deadline(unittest.TestCase):
103
104
  self.server_thread.join(3)
104
105
 
105
106
  def start_child(self):
106
- self.job = subprocess.Popen([sys.executable, "-c", f"import time;time.sleep({CHILD_S});print('finished')"],
107
- stdout=subprocess.PIPE, stderr=subprocess.PIPE)
107
+ self.job = subprocess.Popen([sys.executable, "-c", "import sys;sys.stdin.read();print('finished')"],
108
+ stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.DEVNULL)
108
109
  self.started.set()
109
110
  def collect():
110
- self.payload, _ = self.job.communicate()
111
+ self.payload = self.job.stdout.read()
112
+ self.job.wait()
111
113
  self.completed.set()
112
114
  self.collector = threading.Thread(target=collect)
113
115
  self.collector.start()
114
116
  return {"id": "local-process", "state": "running", "stdinOpen": False, "outputBytes": 0}
115
117
 
118
+ def release_child(self):
119
+ if not self.job.stdin.closed:
120
+ self.job.stdin.close()
121
+
116
122
  def commands(self, asynchronous=False):
117
123
  transport = (AsyncTransport if asynchronous else _Transport)("local-test", self.origin, 2, 0)
118
124
  owner = self
@@ -154,6 +160,7 @@ class Deadline(unittest.TestCase):
154
160
  with self.assertRaises(TimeoutException):
155
161
  commands.run("local child", timeout=DEADLINE_S)
156
162
  self.assert_not_killed()
163
+ self.release_child()
157
164
  result = commands.connect(pid_of("local-process"), timeout=0).wait()
158
165
  self.assertEqual((result.stdout, result.exit_code), ("finished\n", 0))
159
166
  self.assert_not_killed() if self.job.poll() is None else None
@@ -168,6 +175,7 @@ class Deadline(unittest.TestCase):
168
175
  with self.assertRaises(TimeoutException):
169
176
  handle.wait()
170
177
  self.assert_not_killed()
178
+ self.release_child()
171
179
  result = commands.connect(handle.pid, timeout=None).wait()
172
180
  self.assertEqual(result.stdout, "finished\n")
173
181
  finally:
@@ -187,6 +195,7 @@ class Deadline(unittest.TestCase):
187
195
  with self.assertRaises(asyncio.CancelledError):
188
196
  await waiter
189
197
  self.assert_not_killed()
198
+ self.release_child()
190
199
  final = await commands.connect(handle.pid, timeout=0)
191
200
  self.assertEqual((await final.wait()).stdout, "finished\n")
192
201
  finally:
@@ -16,7 +16,7 @@ from withruntime._errors import RuntimeError
16
16
  from withruntime._request_scope import request_scope, current
17
17
 
18
18
 
19
- BODY_DELAY, BUDGET = .3, .1
19
+ BODY_DELAY, BUDGET = .2, .065
20
20
 
21
21
 
22
22
  class InterpreterDeadline(unittest.TestCase):
@@ -12,6 +12,9 @@ from withruntime import AsyncRuntime, InvalidRequestError, PermissionDeniedError
12
12
 
13
13
  class UsageHandler(BaseHTTPRequestHandler):
14
14
  protocol_version = "HTTP/1.1"
15
+ # A header and its body, written apart, each go at once: with Nagle a
16
+ # kept-alive answer waited 40 ms on the client's delayed ACK.
17
+ disable_nagle_algorithm = True
15
18
 
16
19
  def log_message(self, *_):
17
20
  pass
@@ -46,7 +49,7 @@ class CustomerUsage(unittest.TestCase):
46
49
  @classmethod
47
50
  def setUpClass(cls):
48
51
  cls.server = ThreadingHTTPServer(("127.0.0.1", 0), UsageHandler)
49
- cls.thread = threading.Thread(target=cls.server.serve_forever, daemon=True)
52
+ cls.thread = threading.Thread(target=cls.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True)
50
53
  cls.thread.start()
51
54
  cls.url = f"http://127.0.0.1:{cls.server.server_port}"
52
55
 
@@ -25,6 +25,9 @@ class World:
25
25
 
26
26
  class Handler(BaseHTTPRequestHandler):
27
27
  protocol_version = "HTTP/1.1"
28
+ # A header and its body, written apart, each go at once: with Nagle a
29
+ # kept-alive answer waited 40 ms on the client's delayed ACK.
30
+ disable_nagle_algorithm = True
28
31
 
29
32
  def log_message(self, *_):
30
33
  pass
@@ -58,7 +61,7 @@ class World:
58
61
  self.wfile.write(data)
59
62
 
60
63
  self.server = ThreadingHTTPServer(("127.0.0.1", 0), Handler)
61
- self.thread = threading.Thread(target=self.server.serve_forever, daemon=True)
64
+ self.thread = threading.Thread(target=self.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True)
62
65
  self.thread.start()
63
66
  self.url = f"http://127.0.0.1:{self.server.server_address[1]}"
64
67
 
@@ -17,17 +17,23 @@ SANDBOX = {"id": "sbx", "kind": "sandbox", "state": "running", "status": "active
17
17
 
18
18
 
19
19
  class Wire:
20
- """Counts connections open at once. A stream stays open ``hold`` seconds."""
20
+ """Counts connections open at once. A stream stays open ``hold`` seconds,
21
+ or, given ``until_open``, until that many are open at once: the width a
22
+ test proves, reached in milliseconds, where a fixed hold made each test
23
+ wait it out (a second each, 23 October 2026)."""
21
24
 
22
- def __init__(self, is_async, hold=0.015):
25
+ def __init__(self, is_async, hold=0.015, until_open=None):
23
26
  self.is_async, self.hold, self.open, self.peak, self.lock = is_async, hold, 0, 0, threading.Lock()
24
27
  self.count = 0
28
+ self.until_open, self.full = until_open, threading.Event()
25
29
 
26
30
  def _opened(self):
27
31
  with self.lock:
28
32
  self.open += 1
29
33
  self.count += 1
30
34
  self.peak = max(self.peak, self.open)
35
+ if self.until_open is not None and self.open >= self.until_open:
36
+ self.full.set()
31
37
 
32
38
  def _closed(self):
33
39
  with self.lock:
@@ -58,7 +64,12 @@ class Wire:
58
64
 
59
65
  async def lines(self, deadline=None):
60
66
  yield body[0]
61
- await asyncio.sleep(wire.hold)
67
+ if wire.until_open is None:
68
+ await asyncio.sleep(wire.hold)
69
+ else:
70
+ end = time.monotonic() + wire.hold
71
+ while not wire.full.is_set() and time.monotonic() < end:
72
+ await asyncio.sleep(0.002)
62
73
  for line in body[1:]:
63
74
  yield line
64
75
 
@@ -72,7 +83,10 @@ class Wire:
72
83
 
73
84
  def lines(self, deadline=None):
74
85
  yield body[0]
75
- time.sleep(wire.hold)
86
+ if wire.until_open is None:
87
+ time.sleep(wire.hold)
88
+ else:
89
+ wire.full.wait(wire.hold)
76
90
  yield from body[1:]
77
91
 
78
92
  def close(self):
@@ -102,7 +116,7 @@ class ConnectionCap(unittest.TestCase):
102
116
  def test_streams_keep_connections_for_calls_sync_and_async(self):
103
117
  # Twenty streams at once on a cap of twelve: at most four are open
104
118
  # (eight are kept for calls), and calls beside them never wait long.
105
- wire = Wire(True, hold=0.05)
119
+ wire = Wire(True, hold=0.025)
106
120
  client = AsyncRuntime(api_key="rk", base_url="https://api.example.test", max_connections=12)
107
121
  client._t._http = wire
108
122
 
@@ -121,7 +135,7 @@ class ConnectionCap(unittest.TestCase):
121
135
  self.assertLess(calls, 0.04)
122
136
  self.assertLessEqual(wire.peak, 12)
123
137
 
124
- wire = Wire(False, hold=0.05)
138
+ wire = Wire(False, hold=0.025)
125
139
  client = Runtime(api_key="rk", base_url="https://api.example.test", max_connections=12)
126
140
  client._t._http = wire
127
141
  done = []
@@ -166,7 +180,7 @@ class AdapterClientIsWide(unittest.TestCase):
166
180
 
167
181
  def test_a_hundred_commands_at_once_async(self):
168
182
  from withruntime.e2b import _async_sandbox
169
- wire = Wire(True, hold=1.0)
183
+ wire = Wire(True, hold=1.0, until_open=100)
170
184
  client = _async_sandbox._client(None, None)
171
185
  client._t._http = wire
172
186
 
@@ -177,15 +191,15 @@ class AdapterClientIsWide(unittest.TestCase):
177
191
  return results, time.monotonic() - started
178
192
  results, seconds = asyncio.run(main())
179
193
  self.assertTrue(all(r.exit_code == 0 for r in results))
180
- # All 100 open at once is the proof of width; the time only bounds what
181
- # is added around one 1 s hold, with room for a busy check machine.
194
+ # All 100 open at once is the proof of width (each holds until they
195
+ # are, or a second); the time bounds a client that reads them in waves.
182
196
  self.assertEqual(wire.peak, 100)
183
197
  self.assertLess(seconds, 3)
184
198
 
185
199
  def test_a_hundred_commands_at_once_sync(self):
186
200
  from concurrent.futures import ThreadPoolExecutor
187
201
  from withruntime.e2b import _sync_sandbox, Sandbox
188
- wire = Wire(False, hold=1.0)
202
+ wire = Wire(False, hold=1.0, until_open=100)
189
203
  client = _sync_sandbox._client(None, None)
190
204
  client._t._http = wire
191
205
  sbx = Sandbox.create()
@@ -194,8 +208,8 @@ class AdapterClientIsWide(unittest.TestCase):
194
208
  results = list(pool.map(lambda _: sbx.commands.run("sleep 1"), range(100)))
195
209
  seconds = time.monotonic() - started
196
210
  self.assertTrue(all(r.exit_code == 0 for r in results))
197
- # All 100 open at once is the proof of width; the time only bounds what
198
- # is added around one 1 s hold, with room for a busy check machine.
211
+ # All 100 open at once is the proof of width (each holds until they
212
+ # are, or a second); the time bounds a client that reads them in waves.
199
213
  self.assertEqual(wire.peak, 100)
200
214
  self.assertLess(seconds, 3)
201
215
 
@@ -7,6 +7,7 @@ import json
7
7
  import unittest
8
8
 
9
9
  from withruntime import AsyncRuntime, ConnectionError, Runtime
10
+ from tests.instant_sleeps import instant_sleeps
10
11
 
11
12
  ID = "8a1f9c2e-0d1b-4c3a-9e8f-7a6b5c4d3e2f"
12
13
  INFO = json.dumps({"id": ID, "kind": "sandbox", "state": "running", "status": "active"}).encode()
@@ -184,16 +185,20 @@ class Outage(unittest.TestCase):
184
185
  runtime = (AsyncRuntime if is_async else Runtime)(api_key="rk", base_url="https://api.example.test",
185
186
  max_retries=0)
186
187
  runtime._t._http = wire
187
- if is_async:
188
- async def go():
189
- sbx = await runtime.sandboxes.get(ID)
190
- return await sbx.exec("x", on_stdout=lambda _: None)
191
- result = asyncio.run(go())
192
- else:
193
- result = runtime.sandboxes.get(ID).exec("x", on_stdout=lambda _: None)
188
+ # Each reconnect's pause is recorded, not slept.
189
+ with instant_sleeps() as slept:
190
+ if is_async:
191
+ async def go():
192
+ sbx = await runtime.sandboxes.get(ID)
193
+ return await sbx.exec("x", on_stdout=lambda _: None)
194
+ result = asyncio.run(go())
195
+ else:
196
+ result = runtime.sandboxes.get(ID).exec("x", on_stdout=lambda _: None)
194
197
  self.assertEqual(result.exit_code, 0)
195
198
  self.assertEqual(result.stdout, "a\nb\n")
196
199
  self.assertEqual(sum("/output" in t for t in wire.targets), 6)
200
+ # The follow's own pauses double while the spell lasts.
201
+ self.assertEqual(slept[-3:], [0.05, 0.1, 0.2])
197
202
 
198
203
  def test_a_deliberate_refusal_still_ends_the_follow_at_once(self):
199
204
  routes = {":exec": ([{"type": "start", "processId": "p1"}], True)}
@@ -17,6 +17,7 @@ from http.server import BaseHTTPRequestHandler, ThreadingHTTPServer
17
17
 
18
18
  from withruntime import AsyncRuntime, Runtime
19
19
  from withruntime._errors import RuntimeError
20
+ from tests.instant_sleeps import instant_sleeps
20
21
 
21
22
  ID = "8a1f9c2e-0d1b-4c3a-9e8f-7a6b5c4d3e2f"
22
23
  WHOLE = bytes((i * 31) & 0xFF for i in range(3 * 1_048_576 + 7))
@@ -29,6 +30,9 @@ class World:
29
30
 
30
31
  class Handler(BaseHTTPRequestHandler):
31
32
  protocol_version = "HTTP/1.1"
33
+ # A header and its body, written apart, each go at once: with Nagle a
34
+ # kept-alive answer waited 40 ms on the client's delayed ACK.
35
+ disable_nagle_algorithm = True
32
36
 
33
37
  def log_message(self, *args):
34
38
  pass
@@ -64,7 +68,7 @@ class World:
64
68
  self.wfile.write(data)
65
69
 
66
70
  self.server = ThreadingHTTPServer(("127.0.0.1", 0), Handler)
67
- threading.Thread(target=self.server.serve_forever, daemon=True).start()
71
+ threading.Thread(target=self.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True).start()
68
72
  self.url = f"http://localhost:{self.server.server_address[1]}"
69
73
 
70
74
  def close(self):
@@ -73,6 +77,12 @@ class World:
73
77
 
74
78
 
75
79
  class Downloads(unittest.TestCase):
80
+ def setUp(self):
81
+ # A read again waits its back-off first: recorded, not slept.
82
+ sleeps = instant_sleeps()
83
+ self.slept = sleeps.__enter__()
84
+ self.addCleanup(sleeps.__exit__, None, None, None)
85
+
76
86
  def world(self, cuts, sha=None):
77
87
  world = World(cuts, sha)
78
88
  self.addCleanup(world.close)
@@ -90,6 +100,8 @@ class Downloads(unittest.TestCase):
90
100
  self.assertEqual(caught.exception.code, "download_incomplete")
91
101
  self.assertEqual(caught.exception.details, {"received": 30, "expected": len(WHOLE)})
92
102
  self.assertEqual(world.reads, 3)
103
+ self.assertEqual(len(self.slept), 2)
104
+ self.assertGreaterEqual(self.slept[1], 0.25)
93
105
 
94
106
  def test_digest_mismatch_raises(self):
95
107
  _, runtime = self.world([], sha="0" * 64)
@@ -22,6 +22,9 @@ class CutFirstAnswer:
22
22
 
23
23
  class Handler(BaseHTTPRequestHandler):
24
24
  protocol_version = "HTTP/1.1"
25
+ # A header and its body, written apart, each go at once: with Nagle a
26
+ # kept-alive answer waited 40 ms on the client's delayed ACK.
27
+ disable_nagle_algorithm = True
25
28
 
26
29
  def log_message(self, *_):
27
30
  pass
@@ -41,7 +44,7 @@ class CutFirstAnswer:
41
44
  self.wfile.write(body)
42
45
 
43
46
  self.server = ThreadingHTTPServer(("127.0.0.1", 0), Handler)
44
- self.thread = threading.Thread(target=self.server.serve_forever, daemon=True)
47
+ self.thread = threading.Thread(target=self.server.serve_forever, kwargs={"poll_interval": 0.01}, daemon=True)
45
48
  self.thread.start()
46
49
  self.url = f"http://127.0.0.1:{self.server.server_address[1]}"
47
50
 
@@ -44,7 +44,7 @@ class Server:
44
44
  while b"\r\n\r\n" not in request:
45
45
  request += conn.recv(4096)
46
46
  conn.sendall(HEAD)
47
- time.sleep(0.3)
47
+ time.sleep(0.05)
48
48
  if self.then == "rest":
49
49
  conn.sendall(b"0\r\n\r\n")
50
50
  else: