From 6ed8c21849a5b57c67fffd7316066e41390dd455 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Brigitta=20Sip=C5=91cz?= Date: Tue, 26 Sep 2023 15:46:12 -0700 Subject: [PATCH 1/2] BUG: Fix session inheritance for SIA2 --- pyvo/dal/sia2.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/pyvo/dal/sia2.py b/pyvo/dal/sia2.py index 74ea0888d..9aad10c56 100644 --- a/pyvo/dal/sia2.py +++ b/pyvo/dal/sia2.py @@ -120,7 +120,7 @@ def search(url, pos=None, band=None, time=None, pol=None, _SIA2_PARAMETERS """ - service = SIA2Service(url) + service = SIA2Service(url, session=session) return service.search(pos=pos, band=band, time=time, pol=pol, field_of_view=field_of_view, spatial_resolution=spatial_resolution, @@ -130,8 +130,7 @@ def search(url, pos=None, band=None, time=None, pol=None, facility=facility, collection=collection, instrument=instrument, data_type=data_type, calib_level=calib_level, target_name=target_name, - res_format=res_format, maxrec=maxrec, - session=session, **kwargs) + res_format=res_format, maxrec=maxrec, **kwargs) search.__doc__ = search.__doc__.replace('_SIA2_PARAMETERS', @@ -200,8 +199,7 @@ def search(self, pos=None, band=None, time=None, pol=None, spectral_resolving_power=None, exptime=None, timeres=None, publisher_did=None, facility=None, collection=None, instrument=None, data_type=None, calib_level=None, - target_name=None, res_format=None, maxrec=None, session=None, - **kwargs): + target_name=None, res_format=None, maxrec=None, **kwargs): """ Performs a SIA2 search against a SIA2 service @@ -221,7 +219,7 @@ def search(self, pos=None, band=None, time=None, pol=None, instrument=instrument, data_type=data_type, calib_level=calib_level, target_name=target_name, res_format=res_format, maxrec=maxrec, - session=session, **kwargs).execute() + session=self._session, **kwargs).execute() class SIA2Query(DALQuery, AxisParamMixin): From 41b80f128cace8f535e4075fac4812e08f72ae7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Brigitta=20Sip=C5=91cz?= Date: Tue, 26 Sep 2023 15:46:26 -0700 Subject: [PATCH 2/2] DOC: adding changelog --- CHANGES.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGES.rst b/CHANGES.rst index 3b8989b1a..675edfc82 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -34,6 +34,8 @@ 1.4.3 (unreleased) ================== +- Fix session inheritance in SIA2. [#490] + 1.4.2 (2023-08-16) ==================