Skip to content

Commit 0084f93

Browse files
authored
fix(marketplace): order local images by type by default (#582)
1 parent 525a587 commit 0084f93

File tree

4 files changed

+70
-46
lines changed

4 files changed

+70
-46
lines changed

scaleway-async/scaleway_async/marketplace/v2/api.py

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -269,29 +269,29 @@ async def get_version(
269269
async def list_local_images(
270270
self,
271271
*,
272-
image_id: Optional[str] = None,
273-
version_id: Optional[str] = None,
274272
page_size: Optional[int] = None,
275273
page: Optional[int] = None,
276274
order_by: Optional[ListLocalImagesRequestOrderBy] = None,
277-
image_label: Optional[str] = None,
278275
zone: Optional[Zone] = None,
276+
image_id: Optional[str] = None,
277+
version_id: Optional[str] = None,
278+
image_label: Optional[str] = None,
279279
type_: Optional[LocalImageType] = None,
280280
) -> ListLocalImagesResponse:
281281
"""
282282
List local images from a specific image or version.
283283
List information about local images in a specific Availability Zone, specified by its `image_id` (UUID format), `version_id` (UUID format) or `image_label`. Only one of these three parameters may be set.
284-
:param image_id:
284+
:param page_size: A positive integer lower or equal to 100 to select the number of items to display.
285+
:param page: A positive integer to choose the page to display.
286+
:param order_by: Ordering to use.
287+
:param zone: Filter local images available on this Availability Zone.
288+
:param image_id: Filter by image id.
285289
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
286-
:param version_id:
290+
:param version_id: Filter by version id.
287291
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
288-
:param page_size:
289-
:param page:
290-
:param order_by:
291-
:param image_label:
292+
:param image_label: Filter by image label.
292293
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
293-
:param zone: Zone to target. If none is passed will use default zone from the config.
294-
:param type_:
294+
:param type_: Filter by type.
295295
:return: :class:`ListLocalImagesResponse <ListLocalImagesResponse>`
296296
297297
Usage:
@@ -325,29 +325,29 @@ async def list_local_images(
325325
async def list_local_images_all(
326326
self,
327327
*,
328-
image_id: Optional[str] = None,
329-
version_id: Optional[str] = None,
330328
page_size: Optional[int] = None,
331329
page: Optional[int] = None,
332330
order_by: Optional[ListLocalImagesRequestOrderBy] = None,
333-
image_label: Optional[str] = None,
334331
zone: Optional[Zone] = None,
332+
image_id: Optional[str] = None,
333+
version_id: Optional[str] = None,
334+
image_label: Optional[str] = None,
335335
type_: Optional[LocalImageType] = None,
336336
) -> List[LocalImage]:
337337
"""
338338
List local images from a specific image or version.
339339
List information about local images in a specific Availability Zone, specified by its `image_id` (UUID format), `version_id` (UUID format) or `image_label`. Only one of these three parameters may be set.
340-
:param image_id:
340+
:param page_size: A positive integer lower or equal to 100 to select the number of items to display.
341+
:param page: A positive integer to choose the page to display.
342+
:param order_by: Ordering to use.
343+
:param zone: Filter local images available on this Availability Zone.
344+
:param image_id: Filter by image id.
341345
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
342-
:param version_id:
346+
:param version_id: Filter by version id.
343347
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
344-
:param page_size:
345-
:param page:
346-
:param order_by:
347-
:param image_label:
348+
:param image_label: Filter by image label.
348349
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
349-
:param zone: Zone to target. If none is passed will use default zone from the config.
350-
:param type_:
350+
:param type_: Filter by type.
351351
:return: :class:`List[LocalImage] <List[LocalImage]>`
352352
353353
Usage:

scaleway-async/scaleway_async/marketplace/v2/types.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,17 +252,29 @@ class ListImagesResponse:
252252
@dataclass
253253
class ListLocalImagesRequest:
254254
page_size: Optional[int]
255+
"""
256+
A positive integer lower or equal to 100 to select the number of items to display.
257+
"""
255258

256259
page: Optional[int]
260+
"""
261+
A positive integer to choose the page to display.
262+
"""
257263

258264
order_by: Optional[ListLocalImagesRequestOrderBy]
265+
"""
266+
Ordering to use.
267+
"""
259268

260269
zone: Optional[Zone]
261270
"""
262-
Zone to target. If none is passed will use default zone from the config.
271+
Filter local images available on this Availability Zone.
263272
"""
264273

265274
type_: Optional[LocalImageType]
275+
"""
276+
Filter by type.
277+
"""
266278

267279
image_id: Optional[str]
268280

scaleway/scaleway/marketplace/v2/api.py

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -269,29 +269,29 @@ def get_version(
269269
def list_local_images(
270270
self,
271271
*,
272-
image_id: Optional[str] = None,
273-
version_id: Optional[str] = None,
274272
page_size: Optional[int] = None,
275273
page: Optional[int] = None,
276274
order_by: Optional[ListLocalImagesRequestOrderBy] = None,
277-
image_label: Optional[str] = None,
278275
zone: Optional[Zone] = None,
276+
image_id: Optional[str] = None,
277+
version_id: Optional[str] = None,
278+
image_label: Optional[str] = None,
279279
type_: Optional[LocalImageType] = None,
280280
) -> ListLocalImagesResponse:
281281
"""
282282
List local images from a specific image or version.
283283
List information about local images in a specific Availability Zone, specified by its `image_id` (UUID format), `version_id` (UUID format) or `image_label`. Only one of these three parameters may be set.
284-
:param image_id:
284+
:param page_size: A positive integer lower or equal to 100 to select the number of items to display.
285+
:param page: A positive integer to choose the page to display.
286+
:param order_by: Ordering to use.
287+
:param zone: Filter local images available on this Availability Zone.
288+
:param image_id: Filter by image id.
285289
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
286-
:param version_id:
290+
:param version_id: Filter by version id.
287291
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
288-
:param page_size:
289-
:param page:
290-
:param order_by:
291-
:param image_label:
292+
:param image_label: Filter by image label.
292293
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
293-
:param zone: Zone to target. If none is passed will use default zone from the config.
294-
:param type_:
294+
:param type_: Filter by type.
295295
:return: :class:`ListLocalImagesResponse <ListLocalImagesResponse>`
296296
297297
Usage:
@@ -325,29 +325,29 @@ def list_local_images(
325325
def list_local_images_all(
326326
self,
327327
*,
328-
image_id: Optional[str] = None,
329-
version_id: Optional[str] = None,
330328
page_size: Optional[int] = None,
331329
page: Optional[int] = None,
332330
order_by: Optional[ListLocalImagesRequestOrderBy] = None,
333-
image_label: Optional[str] = None,
334331
zone: Optional[Zone] = None,
332+
image_id: Optional[str] = None,
333+
version_id: Optional[str] = None,
334+
image_label: Optional[str] = None,
335335
type_: Optional[LocalImageType] = None,
336336
) -> List[LocalImage]:
337337
"""
338338
List local images from a specific image or version.
339339
List information about local images in a specific Availability Zone, specified by its `image_id` (UUID format), `version_id` (UUID format) or `image_label`. Only one of these three parameters may be set.
340-
:param image_id:
340+
:param page_size: A positive integer lower or equal to 100 to select the number of items to display.
341+
:param page: A positive integer to choose the page to display.
342+
:param order_by: Ordering to use.
343+
:param zone: Filter local images available on this Availability Zone.
344+
:param image_id: Filter by image id.
341345
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
342-
:param version_id:
346+
:param version_id: Filter by version id.
343347
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
344-
:param page_size:
345-
:param page:
346-
:param order_by:
347-
:param image_label:
348+
:param image_label: Filter by image label.
348349
One-Of ('scope'): at most one of 'image_id', 'version_id', 'image_label' could be set.
349-
:param zone: Zone to target. If none is passed will use default zone from the config.
350-
:param type_:
350+
:param type_: Filter by type.
351351
:return: :class:`List[LocalImage] <List[LocalImage]>`
352352
353353
Usage:

scaleway/scaleway/marketplace/v2/types.py

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,17 +252,29 @@ class ListImagesResponse:
252252
@dataclass
253253
class ListLocalImagesRequest:
254254
page_size: Optional[int]
255+
"""
256+
A positive integer lower or equal to 100 to select the number of items to display.
257+
"""
255258

256259
page: Optional[int]
260+
"""
261+
A positive integer to choose the page to display.
262+
"""
257263

258264
order_by: Optional[ListLocalImagesRequestOrderBy]
265+
"""
266+
Ordering to use.
267+
"""
259268

260269
zone: Optional[Zone]
261270
"""
262-
Zone to target. If none is passed will use default zone from the config.
271+
Filter local images available on this Availability Zone.
263272
"""
264273

265274
type_: Optional[LocalImageType]
275+
"""
276+
Filter by type.
277+
"""
266278

267279
image_id: Optional[str]
268280

0 commit comments

Comments
 (0)