Skip to content

Commit f1aa389

Browse files
authored
feat(registry): deprecate delete tag force field (#200)
1 parent bd8a3ea commit f1aa389

File tree

4 files changed

+12
-16
lines changed

4 files changed

+12
-16
lines changed

scaleway-async/scaleway_async/registry/v1/api.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -753,24 +753,21 @@ async def delete_tag(
753753
self,
754754
*,
755755
tag_id: str,
756-
force: bool,
757756
region: Optional[Region] = None,
757+
force: Optional[bool] = None,
758758
) -> Tag:
759759
"""
760760
Delete a tag.
761761
Delete a given image tag. You must specify, in the endpoint, the `region` and `tag_id` parameters of the tag you want to delete.
762762
:param region: Region to target. If none is passed will use default region from the config.
763763
:param tag_id: UUID of the tag.
764-
:param force: If two tags share the same digest the deletion will fail unless this parameter is set to true.
764+
:param force: If two tags share the same digest the deletion will fail unless this parameter is set to true (deprecated).
765765
:return: :class:`Tag <Tag>`
766766
767767
Usage:
768768
::
769769
770-
result = await api.delete_tag(
771-
tag_id="example",
772-
force=True,
773-
)
770+
result = await api.delete_tag(tag_id="example")
774771
"""
775772

776773
param_region = validate_path_param(

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -585,7 +585,8 @@ class DeleteTagRequest:
585585
UUID of the tag.
586586
"""
587587

588-
force: bool
588+
force: Optional[bool]
589589
"""
590-
If two tags share the same digest the deletion will fail unless this parameter is set to true.
590+
If two tags share the same digest the deletion will fail unless this parameter is set to true (deprecated).
591+
:deprecated
591592
"""

scaleway/scaleway/registry/v1/api.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -751,24 +751,21 @@ def delete_tag(
751751
self,
752752
*,
753753
tag_id: str,
754-
force: bool,
755754
region: Optional[Region] = None,
755+
force: Optional[bool] = None,
756756
) -> Tag:
757757
"""
758758
Delete a tag.
759759
Delete a given image tag. You must specify, in the endpoint, the `region` and `tag_id` parameters of the tag you want to delete.
760760
:param region: Region to target. If none is passed will use default region from the config.
761761
:param tag_id: UUID of the tag.
762-
:param force: If two tags share the same digest the deletion will fail unless this parameter is set to true.
762+
:param force: If two tags share the same digest the deletion will fail unless this parameter is set to true (deprecated).
763763
:return: :class:`Tag <Tag>`
764764
765765
Usage:
766766
::
767767
768-
result = api.delete_tag(
769-
tag_id="example",
770-
force=True,
771-
)
768+
result = api.delete_tag(tag_id="example")
772769
"""
773770

774771
param_region = validate_path_param(

scaleway/scaleway/registry/v1/types.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -585,7 +585,8 @@ class DeleteTagRequest:
585585
UUID of the tag.
586586
"""
587587

588-
force: bool
588+
force: Optional[bool]
589589
"""
590-
If two tags share the same digest the deletion will fail unless this parameter is set to true.
590+
If two tags share the same digest the deletion will fail unless this parameter is set to true (deprecated).
591+
:deprecated
591592
"""

0 commit comments

Comments
 (0)