From 0bdc460f539771600eff7d5857a2cd6ec0b9063f Mon Sep 17 00:00:00 2001 From: OpenStack Release Bot Date: Thu, 5 Sep 2024 16:01:14 +0000 Subject: [PATCH 1/3] Update .gitreview for stable/2024.2 Change-Id: I8bc4ced8fcb10aad69a0c278b9e64393ccf4f328 --- .gitreview | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitreview b/.gitreview index be7b3b494..d6d52e29f 100644 --- a/.gitreview +++ b/.gitreview @@ -2,3 +2,4 @@ host=review.opendev.org port=29418 project=openstack/python-magnumclient.git +defaultbranch=stable/2024.2 From a1756e5865354fcbabe3da3f4bd6cdb1e1531e2e Mon Sep 17 00:00:00 2001 From: OpenStack Release Bot Date: Thu, 5 Sep 2024 16:01:17 +0000 Subject: [PATCH 2/3] Update TOX_CONSTRAINTS_FILE for stable/2024.2 Update the URL to the upper-constraints file to point to the redirect rule on releases.openstack.org so that anyone working on this branch will switch to the correct upper-constraints list automatically when the requirements repository branches. Until the requirements repository has as stable/2024.2 branch, tests will continue to use the upper-constraints list on master. Change-Id: If619e0081474216e1074fb2c88d8591fad674f25 --- tox.ini | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tox.ini b/tox.ini index 3b7cf64e5..6c71eeb8a 100644 --- a/tox.ini +++ b/tox.ini @@ -9,7 +9,7 @@ setenv = VIRTUAL_ENV={envdir} PYTHONWARNINGS=default::DeprecationWarning deps = - -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} + -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/2024.2} -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt commands = @@ -19,7 +19,7 @@ commands = [testenv:bandit] basepython = python3 deps = - -c{env:UPPER_CONSTRAINTS_FILE:https://opendev.org/openstack/requirements/raw/branch/master/upper-constraints.txt} + -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/2024.2} -r{toxinidir}/test-requirements.txt commands = bandit -r magnumclient -x tests -n5 -ll From f21205f2f29b586ad5f6f958bac586a21d76d74c Mon Sep 17 00:00:00 2001 From: EsmerlinJM Date: Wed, 11 Dec 2024 11:23:13 -0300 Subject: [PATCH 3/3] [FIX]: check_hostname requires server_hostname in Magnum client Resolve issue with Magnum client when using HTTPS endpoints in Python 3.12. The error occurs due to `check_hostname` requiring `server_hostname` to be set when `CERT_REQUIRED` is used in `SSLContext.wrap_socket`. References: - Python 3.12 SSL documentation: https://docs.python.org/3.12/library/ssl.html#ssl.SSLContext.check_hostname - Related Magnum client commit from version 4.6.0: https://opendev.org/openstack/python-magnumclient/commit/5d8fd3840052e07418e007f336deb99fd58b7e92 Closes-bug: https://bugs.launchpad.net/magnum/+bug/2091103 Change-Id: I0337d55c1b24ffce7c798a81a286989c402efcc1 (cherry picked from commit ecdcc0697cd53592b54078175001755169436761) --- magnumclient/common/httpclient.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/magnumclient/common/httpclient.py b/magnumclient/common/httpclient.py index 7a6f51e7e..327221686 100644 --- a/magnumclient/common/httpclient.py +++ b/magnumclient/common/httpclient.py @@ -307,7 +307,7 @@ def connect(self): if self.cert_file: context.load_cert_chain(self.cert_file, self.key_file) - self.sock = context.wrap_socket(sock) + self.sock = context.wrap_socket(sock, server_hostname=self.host) @staticmethod def get_system_ca_file():