)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b216978968a4dfb1546158d301768ef4435dbbde","unresolved":true,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Partial-bug: 2166351"},{"line_number":18,"context_line":"Change-Id: I7f8da39642f8654da39062e57f2c8f3f92dd03af"},{"line_number":19,"context_line":"Signed-off-by: Artem Goncharov \u003cartem.goncharov@gmail.com\u003e"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"3a0d9a5c_beecba30","line":19,"updated":"2026-09-04 11:20:52.000000000","message":"Per my comment in the next file\n\n```suggestion\nSigned-off-by: Artem Goncharov \u003cartem.goncharov@gmail.com\u003e\nDepends-on: https://review.opendev.org/c/openstack/keystoneauth/+/1003922/\n```","commit_id":"612d09fd8371f3913bfce2e19e6b3e2931b77419"}],"openstack/cloud/openstackcloud.py":[{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"b216978968a4dfb1546158d301768ef4435dbbde","unresolved":true,"context_lines":[{"line_number":304,"context_line":"    def close(self) -\u003e None:"},{"line_number":305,"context_line":"        \"\"\"Release any resources held open.\"\"\""},{"line_number":306,"context_line":"        self.config.set_auth_cache()"},{"line_number":307,"context_line":"        if self._session is not None:"},{"line_number":308,"context_line":"            self._close_session()"},{"line_number":309,"context_line":"        if self.__pool_executor:"},{"line_number":310,"context_line":"            self.__pool_executor.shutdown()"},{"line_number":311,"context_line":"        atexit.unregister(self.close)"},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"    def _close_session(self) -\u003e None:"},{"line_number":314,"context_line":"        \"\"\"Release the connection pool of the keystoneauth1 session."},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"        Prefers an explicit ``close()`` method on the session if the"},{"line_number":317,"context_line":"        keystoneauth1 version in use provides one. Otherwise fall back"},{"line_number":318,"context_line":"        to closing the underlying ``requests.Session`` directly, but"},{"line_number":319,"context_line":"        only if keystoneauth1 created it itself. A session that was"},{"line_number":320,"context_line":"        constructed with an externally supplied ``requests.Session``"},{"line_number":321,"context_line":"        is left untouched, mirroring the ownership rules keystoneauth1"},{"line_number":322,"context_line":"        applies in its own cleanup."},{"line_number":323,"context_line":"        \"\"\""},{"line_number":324,"context_line":"        ks_session \u003d self._session"},{"line_number":325,"context_line":"        close \u003d getattr(ks_session, \u0027close\u0027, None)"},{"line_number":326,"context_line":"        if callable(close):"},{"line_number":327,"context_line":"            close()"},{"line_number":328,"context_line":"            return"},{"line_number":329,"context_line":"        requests_session \u003d getattr(ks_session, \u0027_session\u0027, None)"},{"line_number":330,"context_line":"        if requests_session is not None:"},{"line_number":331,"context_line":"            requests_session.close()"},{"line_number":332,"context_line":""},{"line_number":333,"context_line":"    def __enter__(self) -\u003e Self:"},{"line_number":334,"context_line":"        return self"}],"source_content_type":"text/x-python","patch_set":1,"id":"fb7332a4_82316b57","line":331,"range":{"start_line":307,"start_character":0,"end_line":331,"end_character":36},"updated":"2026-09-04 11:20:52.000000000","message":"Can we just bump the ksa minimum so we can rely on this? I\u0027d be happy to merge and release [the ksa change](https://review.opendev.org/c/openstack/keystoneauth/+/1003922/) asap. This code then becomes:\n\n```suggestion\n        if self._session is not None:\n            self._session.close()\n        if self.__pool_executor:\n            self.__pool_executor.shutdown()\n        atexit.unregister(self.close)\n```\n\nThis assumes error checking is handled by ksa as I\u0027ve suggested [here](https://review.opendev.org/c/openstack/keystoneauth/+/1003922/comment/281e56de_c626ef7c/). If not, we either need to add error checking here or document the fact that errors can be raised?","commit_id":"612d09fd8371f3913bfce2e19e6b3e2931b77419"},{"author":{"_account_id":27900,"name":"Artem Goncharov","email":"artem.goncharov@gmail.com","username":"gtema"},"change_message_id":"773818d4a858ade163ab59ed13c6168f45ce8a1f","unresolved":true,"context_lines":[{"line_number":304,"context_line":"    def close(self) -\u003e None:"},{"line_number":305,"context_line":"        \"\"\"Release any resources held open.\"\"\""},{"line_number":306,"context_line":"        self.config.set_auth_cache()"},{"line_number":307,"context_line":"        if self._session is not None:"},{"line_number":308,"context_line":"            self._close_session()"},{"line_number":309,"context_line":"        if self.__pool_executor:"},{"line_number":310,"context_line":"            self.__pool_executor.shutdown()"},{"line_number":311,"context_line":"        atexit.unregister(self.close)"},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"    def _close_session(self) -\u003e None:"},{"line_number":314,"context_line":"        \"\"\"Release the connection pool of the keystoneauth1 session."},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"        Prefers an explicit ``close()`` method on the session if the"},{"line_number":317,"context_line":"        keystoneauth1 version in use provides one. Otherwise fall back"},{"line_number":318,"context_line":"        to closing the underlying ``requests.Session`` directly, but"},{"line_number":319,"context_line":"        only if keystoneauth1 created it itself. A session that was"},{"line_number":320,"context_line":"        constructed with an externally supplied ``requests.Session``"},{"line_number":321,"context_line":"        is left untouched, mirroring the ownership rules keystoneauth1"},{"line_number":322,"context_line":"        applies in its own cleanup."},{"line_number":323,"context_line":"        \"\"\""},{"line_number":324,"context_line":"        ks_session \u003d self._session"},{"line_number":325,"context_line":"        close \u003d getattr(ks_session, \u0027close\u0027, None)"},{"line_number":326,"context_line":"        if callable(close):"},{"line_number":327,"context_line":"            close()"},{"line_number":328,"context_line":"            return"},{"line_number":329,"context_line":"        requests_session \u003d getattr(ks_session, \u0027_session\u0027, None)"},{"line_number":330,"context_line":"        if requests_session is not None:"},{"line_number":331,"context_line":"            requests_session.close()"},{"line_number":332,"context_line":""},{"line_number":333,"context_line":"    def __enter__(self) -\u003e Self:"},{"line_number":334,"context_line":"        return self"}],"source_content_type":"text/x-python","patch_set":1,"id":"6111cc2a_651bbd5f","line":331,"range":{"start_line":307,"start_character":0,"end_line":331,"end_character":36},"in_reply_to":"4a5df1f6_568e9b46","updated":"2026-09-04 13:26:14.000000000","message":"I am not sure octavia folks themselves would fix this in this release, so I am not sure whether we really need a backport. But to enable this we can maybe merge this change and in the followup bump ksa and eliminate the try/except","commit_id":"612d09fd8371f3913bfce2e19e6b3e2931b77419"},{"author":{"_account_id":15334,"name":"Stephen Finucane","display_name":"stephenfin","email":"stephenfin@redhat.com","username":"sfinucan"},"change_message_id":"52c54588b4837b18624f3e84180675837dcd8dff","unresolved":true,"context_lines":[{"line_number":304,"context_line":"    def close(self) -\u003e None:"},{"line_number":305,"context_line":"        \"\"\"Release any resources held open.\"\"\""},{"line_number":306,"context_line":"        self.config.set_auth_cache()"},{"line_number":307,"context_line":"        if self._session is not None:"},{"line_number":308,"context_line":"            self._close_session()"},{"line_number":309,"context_line":"        if self.__pool_executor:"},{"line_number":310,"context_line":"            self.__pool_executor.shutdown()"},{"line_number":311,"context_line":"        atexit.unregister(self.close)"},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"    def _close_session(self) -\u003e None:"},{"line_number":314,"context_line":"        \"\"\"Release the connection pool of the keystoneauth1 session."},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"        Prefers an explicit ``close()`` method on the session if the"},{"line_number":317,"context_line":"        keystoneauth1 version in use provides one. Otherwise fall back"},{"line_number":318,"context_line":"        to closing the underlying ``requests.Session`` directly, but"},{"line_number":319,"context_line":"        only if keystoneauth1 created it itself. A session that was"},{"line_number":320,"context_line":"        constructed with an externally supplied ``requests.Session``"},{"line_number":321,"context_line":"        is left untouched, mirroring the ownership rules keystoneauth1"},{"line_number":322,"context_line":"        applies in its own cleanup."},{"line_number":323,"context_line":"        \"\"\""},{"line_number":324,"context_line":"        ks_session \u003d self._session"},{"line_number":325,"context_line":"        close \u003d getattr(ks_session, \u0027close\u0027, None)"},{"line_number":326,"context_line":"        if callable(close):"},{"line_number":327,"context_line":"            close()"},{"line_number":328,"context_line":"            return"},{"line_number":329,"context_line":"        requests_session \u003d getattr(ks_session, \u0027_session\u0027, None)"},{"line_number":330,"context_line":"        if requests_session is not None:"},{"line_number":331,"context_line":"            requests_session.close()"},{"line_number":332,"context_line":""},{"line_number":333,"context_line":"    def __enter__(self) -\u003e Self:"},{"line_number":334,"context_line":"        return self"}],"source_content_type":"text/x-python","patch_set":1,"id":"4a5df1f6_568e9b46","line":331,"range":{"start_line":307,"start_character":0,"end_line":331,"end_character":36},"in_reply_to":"fb7332a4_82316b57","updated":"2026-09-04 12:53:31.000000000","message":"Thinking on this more, there is a corresponding bug here that the octavia folks presumably want fixed and backported. I would be okay with splitting this change into two. The first change ignores the new `Session.close` method we\u0027re adding in https://review.opendev.org/c/openstack/keystoneauth/+/1003922 and does the same work itself. This could be backported. The second change would bump the ksa dep and simplify the code as I\u0027ve suggested above. Does that work for you?","commit_id":"612d09fd8371f3913bfce2e19e6b3e2931b77419"}]}
