mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-09-30 07:40:12 +03:00
fix(typing): resolve mypy errors in schemas.compute.iou_nodes
This commit is contained in:
parent
abb564a2fa
commit
aa7941411f
@ -26,9 +26,9 @@ class IOUBase(BaseModel):
|
||||
Common IOU node properties.
|
||||
"""
|
||||
|
||||
name: str
|
||||
path: str = Field(..., description="IOU executable path")
|
||||
application_id: int = Field(..., description="Application ID for running IOU executable")
|
||||
name: Optional[str] = None
|
||||
path: Optional[str] = Field(None, description="IOU executable path")
|
||||
application_id: Optional[int] = Field(None, description="Application ID for running IOU executable")
|
||||
node_id: Optional[UUID] = None
|
||||
usage: Optional[str] = Field(None, description="How to use the node")
|
||||
console: Optional[int] = Field(None, gt=0, le=65535, description="Console TCP port")
|
||||
@ -52,7 +52,9 @@ class IOUCreate(IOUBase):
|
||||
Properties to create an IOU node.
|
||||
"""
|
||||
|
||||
pass
|
||||
name: str
|
||||
path: str = Field(..., description="IOU executable path")
|
||||
application_id: int = Field(..., description="Application ID for running IOU executable")
|
||||
|
||||
|
||||
class IOUUpdate(IOUBase):
|
||||
@ -60,12 +62,13 @@ class IOUUpdate(IOUBase):
|
||||
Properties to update an IOU node.
|
||||
"""
|
||||
|
||||
name: Optional[str] = None
|
||||
path: Optional[str] = Field(None, description="IOU executable path")
|
||||
application_id: Optional[int] = Field(None, description="Application ID for running IOU executable")
|
||||
pass
|
||||
|
||||
|
||||
class IOU(IOUBase):
|
||||
name: str
|
||||
path: str = Field(..., description="IOU executable path")
|
||||
application_id: int = Field(..., description="Application ID for running IOU executable")
|
||||
project_id: UUID = Field(..., description="Project ID")
|
||||
node_directory: str = Field(..., description="Path to the node working directory (read only)")
|
||||
command_line: str = Field(..., description="Last command line used to start IOU (read only)")
|
||||
|
||||
@ -376,7 +376,6 @@ module = [
|
||||
"gns3server.db.tasks", # 12
|
||||
"gns3server.schemas.compute.atm_switch_nodes", # 5
|
||||
"gns3server.schemas.compute.dynamips_nodes", # 1
|
||||
"gns3server.schemas.compute.iou_nodes", # 3
|
||||
"gns3server.schemas.compute.nat_nodes", # 1
|
||||
"gns3server.schemas.compute.qemu_nodes", # 1
|
||||
"gns3server.schemas.compute.virtualbox_nodes", # 2
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user