File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed
Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ class ModalDeploymentConfig(BaseModel):
9595 """Runtime timeout (default timeout for all runtime requests)
9696 """
9797
98- deployment_timeout : float = 1800 .0
98+ deployment_timeout : float = 3600 .0
9999 """Kill deployment after this many seconds no matter what.
100100 This is a useful killing switch to ensure that you don't spend too
101101 much money on modal.
Original file line number Diff line number Diff line change @@ -117,10 +117,10 @@ def __init__(
117117 logger : logging .Logger | None = None ,
118118 image : str | modal .Image | PurePath ,
119119 startup_timeout : float = 0.4 ,
120- runtime_timeout : float = 1800 .0 ,
120+ runtime_timeout : float = 3600 .0 ,
121121 modal_sandbox_kwargs : dict [str , Any ] | None = None ,
122122 install_pipx : bool = True ,
123- deployment_timeout : float = 1800 .0 ,
123+ deployment_timeout : float = 3600 .0 ,
124124 ):
125125 """Deployment for modal.com. The deployment will only start when the
126126 `start` method is being called.
@@ -209,6 +209,10 @@ async def start(
209209 self ,
210210 ):
211211 """Starts the runtime."""
212+ if self ._runtime is not None and self ._sandbox is not None :
213+ self .logger .warning ("Deployment is already started. Ignoring duplicate start() call." )
214+ return
215+
212216 self .logger .info ("Starting modal sandbox" )
213217 self ._hooks .on_custom_step ("Starting modal sandbox" )
214218 t0 = time .time ()
You can’t perform that action at this time.
0 commit comments