Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-hcloud for openSUSE:Factory checked in at 2026-07-02 20:09:55 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-hcloud (Old) and /work/SRC/openSUSE:Factory/.python-hcloud.new.1982 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-hcloud" Thu Jul 2 20:09:55 2026 rev:21 rq:1363028 version:2.22.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-hcloud/python-hcloud.changes 2026-05-18 17:46:49.465346436 +0200 +++ /work/SRC/openSUSE:Factory/.python-hcloud.new.1982/python-hcloud.changes 2026-07-02 20:13:09.381083437 +0200 @@ -1,0 +2,13 @@ +Wed Jul 1 16:18:30 UTC 2026 - Dirk Müller <[email protected]> + +- update to 2.22.0: + * The endpoints `GET /v1/datacenters` and `GET + /v1/datacenters/{id}` are now deprecated and will be removed + after 1 Oct. 2026. After this date, requests to these + endpoints will return `HTTP 410 Gone`. + * The `DatacentersClient`, `Datacenter` and related classes are + now deprecated. + * deprecate datacenters + * retry requests on api bad_gateway error + +------------------------------------------------------------------- Old: ---- hcloud-2.20.0.tar.gz New: ---- hcloud-2.22.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-hcloud.spec ++++++ --- /var/tmp/diff_new_pack.TZ0D3j/_old 2026-07-02 20:13:11.145144508 +0200 +++ /var/tmp/diff_new_pack.TZ0D3j/_new 2026-07-02 20:13:11.153144786 +0200 @@ -18,7 +18,7 @@ %{?sle15_python_module_pythons} Name: python-hcloud -Version: 2.20.0 +Version: 2.22.0 Release: 0 Summary: Hetzner Cloud Python library License: MIT ++++++ hcloud-2.20.0.tar.gz -> hcloud-2.22.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/CHANGELOG.md new/hcloud-2.22.0/CHANGELOG.md --- old/hcloud-2.20.0/CHANGELOG.md 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/CHANGELOG.md 2026-06-18 17:33:29.000000000 +0200 @@ -1,5 +1,25 @@ # Changelog +## [v2.22.0](https://github.com/hetznercloud/hcloud-python/releases/tag/v2.22.0) + +### Datacenters resource is now deprecated + +The endpoints `GET /v1/datacenters` and `GET /v1/datacenters/{id}` are now deprecated and will be removed after 1 Oct. 2026. After this date, requests to these endpoints will return `HTTP 410 Gone`. + +The `DatacentersClient`, `Datacenter` and related classes are now deprecated. + +See the [changelog](https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated) for more details. + +### Features + +- deprecate datacenters (#656) + +## [v2.21.0](https://github.com/hetznercloud/hcloud-python/releases/tag/v2.21.0) + +### Features + +- retry requests on api bad_gateway error (#658) + ## [v2.20.0](https://github.com/hetznercloud/hcloud-python/releases/tag/v2.20.0) ### Load Balancer HTTP Services now support `timeout_idle` diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/PKG-INFO new/hcloud-2.22.0/PKG-INFO --- old/hcloud-2.20.0/PKG-INFO 2026-05-07 16:27:54.505429700 +0200 +++ new/hcloud-2.22.0/PKG-INFO 2026-06-18 17:33:37.063018800 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 2.4 Name: hcloud -Version: 2.20.0 +Version: 2.22.0 Summary: Official Hetzner Cloud python library Home-page: https://github.com/hetznercloud/hcloud-python Author: Hetzner Cloud GmbH @@ -28,14 +28,14 @@ Provides-Extra: docs Requires-Dist: sphinx<9.2,>=9; extra == "docs" Requires-Dist: sphinx-rtd-theme<3.2,>=3; extra == "docs" -Requires-Dist: myst-parser<5.1,>=5; extra == "docs" +Requires-Dist: myst-parser<5.2,>=5; extra == "docs" Requires-Dist: watchdog<6.1,>=6; extra == "docs" Provides-Extra: test -Requires-Dist: coverage<7.14,>=7.13; extra == "test" +Requires-Dist: coverage<7.15,>=7.14; extra == "test" Requires-Dist: pylint<4.1,>=4; extra == "test" Requires-Dist: pytest<9.1,>=9; extra == "test" Requires-Dist: pytest-cov<7.2,>=7; extra == "test" -Requires-Dist: mypy<1.21,>=1.20; extra == "test" +Requires-Dist: mypy<2.2,>=2.1; extra == "test" Requires-Dist: types-python-dateutil; extra == "test" Requires-Dist: types-requests; extra == "test" Dynamic: author diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/docs/conf.py new/hcloud-2.22.0/docs/conf.py --- old/hcloud-2.20.0/docs/conf.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/docs/conf.py 2026-06-18 17:33:29.000000000 +0200 @@ -40,7 +40,7 @@ add_module_names = False # Myst Parser -myst_enable_extensions = ["colon_fence"] +myst_enable_extensions = ["colon_fence", "alert"] # -- Options for HTML output ------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/_client.py new/hcloud-2.22.0/hcloud/_client.py --- old/hcloud-2.20.0/hcloud/_client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/_client.py 2026-06-18 17:33:29.000000000 +0200 @@ -1,6 +1,7 @@ from __future__ import annotations import time +import warnings from http import HTTPStatus from random import uniform from typing import Any, Protocol @@ -129,6 +130,7 @@ - ``conflict`` - ``rate_limit_exceeded`` + - ``bad_gateway`` - ``timeout`` Changes to the retry policy might occur between releases, and will not be considered @@ -180,11 +182,10 @@ timeout=timeout, ) - self.datacenters = DatacentersClient(self) - """DatacentersClient Instance + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", category=DeprecationWarning) + self.datacenters = DatacentersClient(self) - :type: :class:`DatacentersClient <hcloud.datacenters.client.DatacentersClient>` - """ self.locations = LocationsClient(self) """LocationsClient Instance @@ -302,6 +303,28 @@ """ return self._client.request(method, url, **kwargs) + @property + def datacenters(self) -> DatacentersClient: + """DatacentersClient Instance + + .. deprecated:: 2.22.0 + The datacenters client is deprecated and will be removed after the 2026-10-01. + See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated. + + :type: :class:`DatacentersClient <hcloud.datacenters.client.DatacentersClient>` + """ + warnings.warn( + "The datacenters client is deprecated and will be removed after the 2026-10-01. " + "See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated.", + DeprecationWarning, + stacklevel=2, + ) + return self._datacenters + + @datacenters.setter + def datacenters(self, value: DatacentersClient) -> None: + self._datacenters = value + class ClientBase: def __init__( @@ -420,6 +443,7 @@ return exception.code in ( "rate_limit_exceeded", "conflict", + "bad_gateway", "timeout", ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/_version.py new/hcloud-2.22.0/hcloud/_version.py --- old/hcloud-2.20.0/hcloud/_version.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/_version.py 2026-06-18 17:33:29.000000000 +0200 @@ -1,3 +1,3 @@ from __future__ import annotations -__version__ = "2.20.0" # x-releaser-pleaser-version +__version__ = "2.22.0" # x-releaser-pleaser-version diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/core/client.py new/hcloud-2.22.0/hcloud/core/client.py --- old/hcloud-2.20.0/hcloud/core/client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/core/client.py 2026-06-18 17:33:29.000000000 +0200 @@ -109,7 +109,10 @@ """ self._client = client self.complete = complete - self.data_model: Domain = self.model.from_dict(data) + + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", category=DeprecationWarning) + self.data_model: Domain = self.model.from_dict(data) def __getattr__(self, name: str): # type: ignore[no-untyped-def] """Allow magical access to the properties of the model diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/datacenters/client.py new/hcloud-2.22.0/hcloud/datacenters/client.py --- old/hcloud-2.20.0/hcloud/datacenters/client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/datacenters/client.py 2026-06-18 17:33:29.000000000 +0200 @@ -1,12 +1,16 @@ from __future__ import annotations -from typing import Any, NamedTuple +import warnings +from typing import TYPE_CHECKING, Any, NamedTuple from ..core import BoundModelBase, Meta, ResourceClientBase from ..locations import BoundLocation from ..server_types import BoundServerType from .domain import Datacenter, DatacenterServerTypes +if TYPE_CHECKING: + from .._client import Client + __all__ = [ "BoundDatacenter", "DatacentersPageResult", @@ -15,6 +19,12 @@ class BoundDatacenter(BoundModelBase[Datacenter], Datacenter): + """ + .. deprecated:: 2.22.0 + The bound datacenter class is deprecated and will be removed after the 2026-10-01. + See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated. + """ + _client: DatacentersClient model = Datacenter @@ -54,13 +64,34 @@ class DatacentersPageResult(NamedTuple): + """ + .. deprecated:: 2.22.0 + The datacenters page result class is deprecated and will be removed after the 2026-10-01. + See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated. + """ + datacenters: list[BoundDatacenter] meta: Meta class DatacentersClient(ResourceClientBase): + """ + .. deprecated:: 2.22.0 + The datacenters client class is deprecated and will be removed after the 2026-10-01. + See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated. + """ + _base_url = "/datacenters" + def __init__(self, client: Client): + warnings.warn( + "The datacenters client class is deprecated and will be removed after the 2026-10-01. " + "See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated.", + DeprecationWarning, + stacklevel=2, + ) + super().__init__(client) + def get_by_id(self, id: int) -> BoundDatacenter: """Get a specific datacenter by its ID. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/datacenters/domain.py new/hcloud-2.22.0/hcloud/datacenters/domain.py --- old/hcloud-2.20.0/hcloud/datacenters/domain.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/datacenters/domain.py 2026-06-18 17:33:29.000000000 +0200 @@ -18,6 +18,10 @@ class Datacenter(BaseDomain, DomainIdentityMixin): """Datacenter Domain + .. deprecated:: 2.22.0 + The datacenters domain class is deprecated and will be removed after the 2026-10-01. + See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated. + :param id: int ID of Datacenter :param name: str Name of Datacenter :param description: str Description of Datacenter @@ -37,6 +41,12 @@ location: Location | None = None, server_types: DatacenterServerTypes | None = None, ): + warnings.warn( + "The datacenter domain class is deprecated and will be removed after the 2026-10-01. " + "See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated.", + DeprecationWarning, + stacklevel=2, + ) self.id = id self.name = name self.description = description @@ -69,6 +79,10 @@ class DatacenterServerTypes(BaseDomain): """DatacenterServerTypes Domain + .. deprecated:: 2.22.0 + The datacenters domain class is deprecated and will be removed after the 2026-10-01. + See https://docs.hetzner.cloud/changelog#2026-06-02-datacenters-deprecated. + :param available: List[:class:`BoundServerTypes <hcloud.server_types.client.BoundServerTypes>`] All available server types for this datacenter :param supported: List[:class:`BoundServerTypes <hcloud.server_types.client.BoundServerTypes>`] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/primary_ips/client.py new/hcloud-2.22.0/hcloud/primary_ips/client.py --- old/hcloud-2.20.0/hcloud/primary_ips/client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/primary_ips/client.py 2026-06-18 17:33:29.000000000 +0200 @@ -44,7 +44,9 @@ raw = data.get("datacenter", {}) if raw: - data["datacenter"] = BoundDatacenter(client._parent.datacenters, raw) + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", category=DeprecationWarning) + data["datacenter"] = BoundDatacenter(client._parent.datacenters, raw) raw = data.get("location", {}) if raw: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud/servers/client.py new/hcloud-2.22.0/hcloud/servers/client.py --- old/hcloud-2.20.0/hcloud/servers/client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/hcloud/servers/client.py 2026-06-18 17:33:29.000000000 +0200 @@ -77,7 +77,9 @@ ): raw = data.get("datacenter") if raw: - data["datacenter"] = BoundDatacenter(client._parent.datacenters, raw) + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", category=DeprecationWarning) + data["datacenter"] = BoundDatacenter(client._parent.datacenters, raw) raw = data.get("location") if raw: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud.egg-info/PKG-INFO new/hcloud-2.22.0/hcloud.egg-info/PKG-INFO --- old/hcloud-2.20.0/hcloud.egg-info/PKG-INFO 2026-05-07 16:27:54.000000000 +0200 +++ new/hcloud-2.22.0/hcloud.egg-info/PKG-INFO 2026-06-18 17:33:37.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 2.4 Name: hcloud -Version: 2.20.0 +Version: 2.22.0 Summary: Official Hetzner Cloud python library Home-page: https://github.com/hetznercloud/hcloud-python Author: Hetzner Cloud GmbH @@ -28,14 +28,14 @@ Provides-Extra: docs Requires-Dist: sphinx<9.2,>=9; extra == "docs" Requires-Dist: sphinx-rtd-theme<3.2,>=3; extra == "docs" -Requires-Dist: myst-parser<5.1,>=5; extra == "docs" +Requires-Dist: myst-parser<5.2,>=5; extra == "docs" Requires-Dist: watchdog<6.1,>=6; extra == "docs" Provides-Extra: test -Requires-Dist: coverage<7.14,>=7.13; extra == "test" +Requires-Dist: coverage<7.15,>=7.14; extra == "test" Requires-Dist: pylint<4.1,>=4; extra == "test" Requires-Dist: pytest<9.1,>=9; extra == "test" Requires-Dist: pytest-cov<7.2,>=7; extra == "test" -Requires-Dist: mypy<1.21,>=1.20; extra == "test" +Requires-Dist: mypy<2.2,>=2.1; extra == "test" Requires-Dist: types-python-dateutil; extra == "test" Requires-Dist: types-requests; extra == "test" Dynamic: author diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/hcloud.egg-info/requires.txt new/hcloud-2.22.0/hcloud.egg-info/requires.txt --- old/hcloud-2.20.0/hcloud.egg-info/requires.txt 2026-05-07 16:27:54.000000000 +0200 +++ new/hcloud-2.22.0/hcloud.egg-info/requires.txt 2026-06-18 17:33:37.000000000 +0200 @@ -4,14 +4,14 @@ [docs] sphinx<9.2,>=9 sphinx-rtd-theme<3.2,>=3 -myst-parser<5.1,>=5 +myst-parser<5.2,>=5 watchdog<6.1,>=6 [test] -coverage<7.14,>=7.13 +coverage<7.15,>=7.14 pylint<4.1,>=4 pytest<9.1,>=9 pytest-cov<7.2,>=7 -mypy<1.21,>=1.20 +mypy<2.2,>=2.1 types-python-dateutil types-requests diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/setup.py new/hcloud-2.22.0/setup.py --- old/hcloud-2.20.0/setup.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/setup.py 2026-06-18 17:33:29.000000000 +0200 @@ -7,7 +7,7 @@ setup( name="hcloud", - version="2.20.0", # x-releaser-pleaser-version + version="2.22.0", # x-releaser-pleaser-version keywords="hcloud hetzner cloud", description="Official Hetzner Cloud python library", long_description=readme, @@ -42,15 +42,15 @@ "docs": [ "sphinx>=9,<9.2", "sphinx-rtd-theme>=3,<3.2", - "myst-parser>=5,<5.1", + "myst-parser>=5,<5.2", "watchdog>=6,<6.1", ], "test": [ - "coverage>=7.13,<7.14", + "coverage>=7.14,<7.15", "pylint>=4,<4.1", "pytest>=9,<9.1", "pytest-cov>=7,<7.2", - "mypy>=1.20,<1.21", + "mypy>=2.1,<2.2", "types-python-dateutil", "types-requests", ], diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/tests/unit/actions/test_client.py new/hcloud-2.22.0/tests/unit/actions/test_client.py --- old/hcloud-2.20.0/tests/unit/actions/test_client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/tests/unit/actions/test_client.py 2026-06-18 17:33:29.000000000 +0200 @@ -1,6 +1,7 @@ from __future__ import annotations import inspect +import warnings from unittest import mock import pytest @@ -47,10 +48,15 @@ """ Ensure that the list of resource clients above is up to date. """ - members = inspect.getmembers( - client, - predicate=lambda p: isinstance(p, ResourceClientBase) and hasattr(p, "actions"), - ) + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", category=DeprecationWarning) + + members = inspect.getmembers( + client, + predicate=lambda p: isinstance(p, ResourceClientBase) + and hasattr(p, "actions"), + ) + for name, member in members: assert name in resources_with_actions diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/tests/unit/datacenters/test_client.py new/hcloud-2.22.0/tests/unit/datacenters/test_client.py --- old/hcloud-2.20.0/tests/unit/datacenters/test_client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/tests/unit/datacenters/test_client.py 2026-06-18 17:33:29.000000000 +0200 @@ -1,5 +1,6 @@ from __future__ import annotations +import warnings from unittest import mock # noqa: F401 import pytest # noqa: F401 @@ -8,6 +9,8 @@ from hcloud.datacenters import BoundDatacenter, DatacentersClient, DatacenterServerTypes from hcloud.locations import BoundLocation +warnings.filterwarnings("ignore", category=DeprecationWarning) + class TestBoundDatacenter: def test_bound_datacenter_init(self, datacenter_response): @@ -64,7 +67,9 @@ class TestDatacentersClient: @pytest.fixture() def datacenters_client(self, client: Client): - return DatacentersClient(client) + with warnings.catch_warnings(): + warnings.filterwarnings("ignore", category=DeprecationWarning) + return DatacentersClient(client) def test_get_by_id( self, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/tests/unit/datacenters/test_domain.py new/hcloud-2.22.0/tests/unit/datacenters/test_domain.py --- old/hcloud-2.20.0/tests/unit/datacenters/test_domain.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/tests/unit/datacenters/test_domain.py 2026-06-18 17:33:29.000000000 +0200 @@ -1,9 +1,13 @@ from __future__ import annotations +import warnings + import pytest from hcloud.datacenters import Datacenter, DatacenterServerTypes +warnings.filterwarnings("ignore", category=DeprecationWarning) + @pytest.mark.parametrize( "value", diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/hcloud-2.20.0/tests/unit/test_client.py new/hcloud-2.22.0/tests/unit/test_client.py --- old/hcloud-2.20.0/tests/unit/test_client.py 2026-05-07 16:27:46.000000000 +0200 +++ new/hcloud-2.22.0/tests/unit/test_client.py 2026-06-18 17:33:29.000000000 +0200 @@ -107,6 +107,10 @@ True, ), ( + APIException(code="bad_gateway", message="Error", details=None), + True, + ), + ( APIException(code=409, message="Conflict", details=None), False, ),
