Skip to content

Commit b64276e

Browse files
authored
feat: add field custom_partitioning_supported to OS (#652)
1 parent 3b4b287 commit b64276e

File tree

4 files changed

+72
-54
lines changed

4 files changed

+72
-54
lines changed

scaleway-async/scaleway_async/baremetal/v1/marshalling.py

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -141,18 +141,6 @@ def unmarshal_OS(data: Any) -> OS:
141141
if field is not None:
142142
args["logo_url"] = field
143143

144-
field = data.get("enabled", None)
145-
if field is not None:
146-
args["enabled"] = field
147-
148-
field = data.get("license_required", None)
149-
if field is not None:
150-
args["license_required"] = field
151-
152-
field = data.get("allowed", None)
153-
if field is not None:
154-
args["allowed"] = field
155-
156144
field = data.get("ssh", None)
157145
if field is not None:
158146
args["ssh"] = unmarshal_OSOSField(field)
@@ -183,6 +171,22 @@ def unmarshal_OS(data: Any) -> OS:
183171
else:
184172
args["service_password"] = None
185173

174+
field = data.get("enabled", None)
175+
if field is not None:
176+
args["enabled"] = field
177+
178+
field = data.get("license_required", None)
179+
if field is not None:
180+
args["license_required"] = field
181+
182+
field = data.get("allowed", None)
183+
if field is not None:
184+
args["allowed"] = field
185+
186+
field = data.get("custom_partitioning_supported", None)
187+
if field is not None:
188+
args["custom_partitioning_supported"] = field
189+
186190
return OS(**args)
187191

188192

scaleway-async/scaleway_async/baremetal/v1/types.py

Lines changed: 20 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -474,21 +474,6 @@ class OS:
474474
URL of this OS's logo.
475475
"""
476476

477-
enabled: bool
478-
"""
479-
Defines if the operating system is enabled or not.
480-
"""
481-
482-
license_required: bool
483-
"""
484-
License required (check server options for pricing details).
485-
"""
486-
487-
allowed: bool
488-
"""
489-
Defines if a specific Organization is allowed to install this OS type.
490-
"""
491-
492477
ssh: Optional[OSOSField]
493478
"""
494479
Object defining the SSH requirements to install the OS.
@@ -514,6 +499,26 @@ class OS:
514499
Object defining the password requirements to install the service.
515500
"""
516501

502+
enabled: bool
503+
"""
504+
Defines if the operating system is enabled or not.
505+
"""
506+
507+
license_required: bool
508+
"""
509+
License required (check server options for pricing details).
510+
"""
511+
512+
allowed: bool
513+
"""
514+
Defines if a specific Organization is allowed to install this OS type.
515+
"""
516+
517+
custom_partitioning_supported: bool
518+
"""
519+
Defines if custom partitioning is supported by this OS.
520+
"""
521+
517522

518523
@dataclass
519524
class Offer:

scaleway/scaleway/baremetal/v1/marshalling.py

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -141,18 +141,6 @@ def unmarshal_OS(data: Any) -> OS:
141141
if field is not None:
142142
args["logo_url"] = field
143143

144-
field = data.get("enabled", None)
145-
if field is not None:
146-
args["enabled"] = field
147-
148-
field = data.get("license_required", None)
149-
if field is not None:
150-
args["license_required"] = field
151-
152-
field = data.get("allowed", None)
153-
if field is not None:
154-
args["allowed"] = field
155-
156144
field = data.get("ssh", None)
157145
if field is not None:
158146
args["ssh"] = unmarshal_OSOSField(field)
@@ -183,6 +171,22 @@ def unmarshal_OS(data: Any) -> OS:
183171
else:
184172
args["service_password"] = None
185173

174+
field = data.get("enabled", None)
175+
if field is not None:
176+
args["enabled"] = field
177+
178+
field = data.get("license_required", None)
179+
if field is not None:
180+
args["license_required"] = field
181+
182+
field = data.get("allowed", None)
183+
if field is not None:
184+
args["allowed"] = field
185+
186+
field = data.get("custom_partitioning_supported", None)
187+
if field is not None:
188+
args["custom_partitioning_supported"] = field
189+
186190
return OS(**args)
187191

188192

scaleway/scaleway/baremetal/v1/types.py

Lines changed: 20 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -474,21 +474,6 @@ class OS:
474474
URL of this OS's logo.
475475
"""
476476

477-
enabled: bool
478-
"""
479-
Defines if the operating system is enabled or not.
480-
"""
481-
482-
license_required: bool
483-
"""
484-
License required (check server options for pricing details).
485-
"""
486-
487-
allowed: bool
488-
"""
489-
Defines if a specific Organization is allowed to install this OS type.
490-
"""
491-
492477
ssh: Optional[OSOSField]
493478
"""
494479
Object defining the SSH requirements to install the OS.
@@ -514,6 +499,26 @@ class OS:
514499
Object defining the password requirements to install the service.
515500
"""
516501

502+
enabled: bool
503+
"""
504+
Defines if the operating system is enabled or not.
505+
"""
506+
507+
license_required: bool
508+
"""
509+
License required (check server options for pricing details).
510+
"""
511+
512+
allowed: bool
513+
"""
514+
Defines if a specific Organization is allowed to install this OS type.
515+
"""
516+
517+
custom_partitioning_supported: bool
518+
"""
519+
Defines if custom partitioning is supported by this OS.
520+
"""
521+
517522

518523
@dataclass
519524
class Offer:

0 commit comments

Comments
 (0)