Skip to content

Commit 1bd737c

Browse files
authored
Merge pull request #3180 from bsipocz/MAINT_mixed_fixes
MAINT: mixed minor fixes before release
2 parents aeb1e0c + 1538b70 commit 1bd737c

File tree

6 files changed

+21
-52
lines changed

6 files changed

+21
-52
lines changed

.mailmap

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ Austen Groener <[email protected]> <[email protected]>
1111
Ayush Yadav <[email protected]>
1212
Benjamin Alan Weaver <[email protected]> <[email protected]>
1313
Benjamin Alan Weaver <[email protected]> <[email protected]>
14+
15+
1416
Brigitta Sipőcz <[email protected]>
1517
1618
Caden Armstrong <[email protected]>
@@ -19,6 +21,8 @@ Clara Brasseur <[email protected]>
1921
2022
2123
24+
25+
2226
Dino Bektesevic <[email protected]>
2327
E. Madison Bray <[email protected]>
2428
@@ -57,6 +61,7 @@ Jon Juaristi Campillo <[email protected]>
5761
Jonathan Gagne <[email protected]>
5862
5963
Jorge Fernandez Hernandez <[email protected]>
64+
Jorge Fernandez Hernandez <[email protected]> <[email protected]>
6065
Juan Carlos Segovia <[email protected]>
6166
Juanjo Bazán <[email protected]>
6267
Julien Milli <[email protected]>
@@ -91,6 +96,7 @@ Prajwel Joseph <[email protected]>
9196
Raul Gutierrez <[email protected]> <Raul [email protected]>
9297
9398
Rounak Agarwal <[email protected]>
99+
94100
95101
Sashank Mishra <[email protected]>
96102

astroquery/alma/core.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -652,8 +652,8 @@ def query_sia(self, *, pos=None, band=None, time=None, pol=None,
652652
653653
Returns
654654
-------
655-
Results in ``pyvo.dal.sia2.SIA2Results`` format.
656-
result.table in Astropy table format
655+
Results in `~pyvo.dal.sia2.SIA2Results` format.
656+
result.to_qtable in `~astropy.table.QTable` format
657657
"""
658658
return self.sia.search(
659659
pos=pos,
@@ -680,13 +680,13 @@ def query_sia(self, *, pos=None, band=None, time=None, pol=None,
680680

681681
def query_tap(self, query, *, maxrec=None, uploads=None):
682682
"""
683-
Send query to the ALMA TAP. Results in pyvo.dal.TapResult format.
684-
result.table in Astropy table format
683+
Send query to the ALMA TAP. Results in `~pyvo.dal.TAPResults` format.
684+
result.to_qtable in `~astropy.table.QTable` format
685685
686686
Parameters
687687
----------
688688
query : str
689-
ADQL query to execute
689+
ADQL query to be executed
690690
maxrec : int
691691
maximum number of records to return
692692
uploads : dict
@@ -702,6 +702,11 @@ def query_tap(self, query, *, maxrec=None, uploads=None):
702702
>>> uploads = {'tmptable': '/tmp/tmptable_def.xml'}
703703
>>> rslt = query_tap(self, query, maxrec=None, uploads=uploads)
704704
705+
Return
706+
------
707+
result : `~pyvo.dal.TAPResults`
708+
TAP query result
709+
705710
"""
706711
log.debug('TAP query: {}'.format(query))
707712
return self.tap.search(query, language='ADQL', maxrec=maxrec, uploads=uploads)

astroquery/esa/xmm_newton/tests/test_xmm_newton_remote.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ def test_download_data(self, tmp_cwd):
124124
'level': "ODF",
125125
'filename': 'file',
126126
'verbose': False}
127-
xsa = XMMNewtonClass(self.get_dummy_tap_handler())
127+
xsa = XMMNewtonClass()
128128
xsa.download_data(**parameters)
129129

130130
def test_download_data_single_file(self, tmp_cwd):
@@ -135,23 +135,23 @@ def test_download_data_single_file(self, tmp_cwd):
135135
'instname': 'OM',
136136
'extension': 'FTZ',
137137
'verbose': False}
138-
xsa = XMMNewtonClass(self.get_dummy_tap_handler())
138+
xsa = XMMNewtonClass()
139139
xsa.download_data(**parameters)
140140

141141
def test_get_postcard(self, tmp_cwd):
142142
parameters = {'observation_id': "0112880801",
143143
'image_type': "OBS_EPIC",
144144
'filename': None,
145145
'verbose': False}
146-
xsa = XMMNewtonClass(self.get_dummy_tap_handler())
146+
xsa = XMMNewtonClass()
147147
xsa.get_postcard(**parameters)
148148

149149
def test_get_postcard_filename(self, tmp_cwd):
150150
parameters = {'observation_id': "0112880801",
151151
'image_type': "OBS_EPIC",
152152
'filename': "test",
153153
'verbose': False}
154-
xsa = XMMNewtonClass(self.get_dummy_tap_handler())
154+
xsa = XMMNewtonClass()
155155
xsa.get_postcard(**parameters)
156156

157157
def test_get_epic_metadata(self):

astroquery/exoplanet_orbit_database/tests/test_exoplanet_orbit_database.py

Lines changed: 0 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,10 @@
33
import pytest
44
import astropy.units as u
55
from astropy.tests.helper import assert_quantity_allclose
6-
from astropy.utils import minversion
76
from astropy.coordinates import SkyCoord
87

98
from ...exoplanet_orbit_database import ExoplanetOrbitDatabase
109

11-
APY_LT12 = not minversion('astropy', '1.2')
1210
LOCAL_TABLE_PATH = os.path.join(os.path.abspath(os.path.dirname(__file__)),
1311
'data', 'exoplanet_orbit_database.csv')
1412

@@ -54,25 +52,6 @@ def test_hd209458b_exoplanet_orbit_database():
5452
assert params['TRANSIT']
5553

5654

57-
@pytest.mark.remote_data
58-
@pytest.mark.skipif('APY_LT12')
59-
def test_hd209458b_exoplanet_orbit_database_apy_lt12():
60-
# Testing intentionally un-stripped string:
61-
params = ExoplanetOrbitDatabase.query_planet('HD 209458 b ')
62-
assert_quantity_allclose(params["R"], 1.320 * u.Unit('R_jup'),
63-
atol=0.1 * u.Unit('R_jup'))
64-
65-
66-
@pytest.mark.remote_data
67-
@pytest.mark.skipif('not APY_LT12')
68-
def test_hd209458b_exoplanet_orbit_database_apy_gt12():
69-
# Testing intentionally un-stripped string:
70-
with pytest.raises(ValueError):
71-
params = ExoplanetOrbitDatabase.query_planet('HD 209458 b ')
72-
assert_quantity_allclose(params['R'], 1.320 * u.Unit('R_jup'),
73-
atol=0.1 * u.Unit('R_jup'))
74-
75-
7655
@pytest.mark.remote_data
7756
def test_hd209458b_exoplanet_orbit_database_coords():
7857
params = ExoplanetOrbitDatabase.query_planet('HD 209458 b ')
@@ -100,25 +79,6 @@ def test_hd209458b_exoplanet_orbit_database_local():
10079
assert params['TRANSIT']
10180

10281

103-
@pytest.mark.skipif('APY_LT12')
104-
def test_hd209458b_exoplanet_orbit_database_apy_lt12_local():
105-
# Testing intentionally un-stripped string:
106-
params = ExoplanetOrbitDatabase.query_planet('HD 209458 b ',
107-
table_path=LOCAL_TABLE_PATH)
108-
assert_quantity_allclose(params["R"], 1.320 * u.Unit('R_jup'),
109-
atol=0.1 * u.Unit('R_jup'))
110-
111-
112-
@pytest.mark.skipif('not APY_LT12')
113-
def test_hd209458b_exoplanet_orbit_database_apy_gt12_local():
114-
# Testing intentionally un-stripped string:
115-
with pytest.raises(ValueError):
116-
params = ExoplanetOrbitDatabase.query_planet('HD 209458 b ',
117-
table_path=LOCAL_TABLE_PATH)
118-
assert_quantity_allclose(params['R'], 1.320 * u.Unit('R_jup'),
119-
atol=0.1 * u.Unit('R_jup'))
120-
121-
12282
def test_hd209458b_exoplanet_orbit_database_coords_local():
12383
params = ExoplanetOrbitDatabase.query_planet('HD 209458 b ',
12484
table_path=LOCAL_TABLE_PATH)

astroquery/ipac/irsa/core.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ def query_sia(self, *, pos=None, band=None, time=None, pol=None,
9191
Returns
9292
-------
9393
Results in `pyvo.dal.SIAResults` format.
94-
result.table in Astropy table format
94+
result.to_table() in Astropy table format
9595
"""
9696
return self.sia.search(
9797
pos=pos,

docs/jplhorizons/jplhorizons.rst

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -561,8 +561,6 @@ provided as ISO dates (YYYY-MM-DD HH-MM UT). If you have your epoch dates in one
561561
of these formats but you need the other format, make use of
562562
:class:`astropy.time.Time` for the conversion. An example is provided here:
563563

564-
.. doctest-requires:: astropy
565-
566564
>>> from astropy.time import Time
567565
>>> mydate_fromiso = Time('2018-07-23 15:55:23') # pass date as string
568566
>>> print(mydate_fromiso.jd) # convert Time object to Julian date

0 commit comments

Comments
 (0)