Skip to content

feat(baremetal): add max_size instead of specific size for partitioning #908

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions scaleway-async/scaleway_async/baremetal/v1/marshalling.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ def unmarshal_SchemaPartition(data: Any) -> SchemaPartition:
if field is not None:
args["size"] = field

field = data.get("use_all_available_space", None)
if field is not None:
args["use_all_available_space"] = field

return SchemaPartition(**args)


Expand Down Expand Up @@ -1417,6 +1421,9 @@ def marshal_SchemaPartition(
if request.size is not None:
output["size"] = request.size

if request.use_all_available_space is not None:
output["use_all_available_space"] = request.use_all_available_space

return output


Expand Down
2 changes: 2 additions & 0 deletions scaleway-async/scaleway_async/baremetal/v1/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,8 @@ class SchemaPartition:

size: int

use_all_available_space: bool


@dataclass
class SchemaPool:
Expand Down
7 changes: 7 additions & 0 deletions scaleway/scaleway/baremetal/v1/marshalling.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ def unmarshal_SchemaPartition(data: Any) -> SchemaPartition:
if field is not None:
args["size"] = field

field = data.get("use_all_available_space", None)
if field is not None:
args["use_all_available_space"] = field

return SchemaPartition(**args)


Expand Down Expand Up @@ -1417,6 +1421,9 @@ def marshal_SchemaPartition(
if request.size is not None:
output["size"] = request.size

if request.use_all_available_space is not None:
output["use_all_available_space"] = request.use_all_available_space

return output


Expand Down
2 changes: 2 additions & 0 deletions scaleway/scaleway/baremetal/v1/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,8 @@ class SchemaPartition:

size: int

use_all_available_space: bool


@dataclass
class SchemaPool:
Expand Down