You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I tried to deploy Daytona locally and then create a sandbox using daytona_sdk, but it failed with the following error:
daytona_sdk.common.errors.DaytonaError: Failed to create sandbox: {"error":"Key: 'CreateWorkspaceDTO.Id' Error:Field validation for 'Id' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.Name' Error:Field validation for 'Name' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.Source' Error:Field validation for 'Source' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.EnvVars' Error:Field validation for 'EnvVars' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.Labels' Error:Field validation for 'Labels' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.TargetId' Error:Field validation for 'TargetId' failed on the 'required' tag"}
I checked the source code and found that the parameters in the latest code of Daytona are inconsistent with those used in the daytona_api_client of daytona_sdk, as follows:
# daytona_api_client-0.17.1/daytona_api_client/models/create_workspace.py:25classCreateWorkspace(BaseModel):
""" CreateWorkspace """# noqa: E501image: Optional[StrictStr] =Field(default=None, description="The image used for the workspace")
user: Optional[StrictStr] =Field(default=None, description="The user associated with the project")
env: Optional[Dict[str, StrictStr]] =Field(default=None, description="Environment variables for the workspace")
labels: Optional[Dict[str, StrictStr]] =Field(default=None, description="Labels for the workspace")
public: Optional[StrictBool] =Field(default=None, description="Whether the workspace http preview is publicly accessible")
var_class: Optional[StrictStr] =Field(default=None, description="The workspace class type", alias="class")
target: Optional[StrictStr] =Field(default=None, description="The target (region) where the workspace will be created")
cpu: Optional[StrictInt] =Field(default=None, description="CPU cores allocated to the workspace")
gpu: Optional[StrictInt] =Field(default=None, description="GPU units allocated to the workspace")
memory: Optional[StrictInt] =Field(default=None, description="Memory allocated to the workspace in MB")
disk: Optional[StrictInt] =Field(default=None, description="Disk space allocated to the workspace in GB")
auto_stop_interval: Optional[StrictInt] =Field(default=None, description="Auto-stop interval in minutes (0 means disabled)", alias="autoStopInterval")
additional_properties: Dict[str, Any] = {}
__properties: ClassVar[List[str]] = ["image", "user", "env", "labels", "public", "class", "target", "cpu", "gpu", "memory", "disk", "autoStopInterval"]
Describe the bug
I tried to deploy Daytona locally and then create a sandbox using daytona_sdk, but it failed with the following error:
daytona_sdk.common.errors.DaytonaError: Failed to create sandbox: {"error":"Key: 'CreateWorkspaceDTO.Id' Error:Field validation for 'Id' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.Name' Error:Field validation for 'Name' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.Source' Error:Field validation for 'Source' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.EnvVars' Error:Field validation for 'EnvVars' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.Labels' Error:Field validation for 'Labels' failed on the 'required' tag\nKey: 'CreateWorkspaceDTO.TargetId' Error:Field validation for 'TargetId' failed on the 'required' tag"}
I checked the source code and found that the parameters in the latest code of Daytona are inconsistent with those used in the daytona_api_client of daytona_sdk, as follows:
To Reproduce
Expected behavior
What is the issue here, and how can I resolve it?
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: