Skip to content

Commit 9685f00

Browse files
committed
refactor(sandbox): remove network mode validation for CODE_INTERPRETER template type
Removed the validation logic that prevented CODE_INTERPRETER and AIO template types from using PRIVATE network mode, as this restriction is no longer needed. 移除了阻止CODE_INTERPRETER和AIO模板类型使用PRIVATE网络模式的验证逻辑,因为此限制不再需要。 Change-Id: Ice27c23b6833956f59a863105d9583b29de70076 Signed-off-by: OhYee <[email protected]>
1 parent c0e7489 commit 9685f00

File tree

1 file changed

+0
-13
lines changed

1 file changed

+0
-13
lines changed

agentrun/sandbox/model.py

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -337,19 +337,6 @@ def validate_template_constraints(self):
337337
f"the current disk size is {self.disk_size}"
338338
)
339339

340-
if (
341-
self.template_type == TemplateType.CODE_INTERPRETER
342-
or self.template_type == TemplateType.AIO
343-
):
344-
if (
345-
self.network_configuration
346-
and self.network_configuration.network_mode
347-
== TemplateNetworkMode.PRIVATE
348-
):
349-
raise ValueError(
350-
"when template_type is CODE_INTERPRETER,"
351-
"network_mode cannot be PRIVATE"
352-
)
353340
return self
354341

355342

0 commit comments

Comments
 (0)