Skip to content

Commit a5a390d

Browse files
authored
Merge pull request #2544 from bsipocz/doc_fix_doctest_202209
MAINT: fix narrative doctests
2 parents eae5614 + befe009 commit a5a390d

File tree

3 files changed

+16
-23
lines changed

3 files changed

+16
-23
lines changed

docs/dace/dace.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ If you need to get radial velocities data for an object you can do the following
2020

2121
>>> from astroquery.dace import Dace
2222
>>> radial_velocities_table = Dace.query_radial_velocities('HD40307')
23-
>>> radial_velocities_table.pprint(max_lines=5, max_width=120)
23+
>>> radial_velocities_table.pprint(max_lines=5, max_width=120) # doctest: +IGNORE_OUTPUT
2424
berv berv_err ... date_night raw_file
2525
----------------- -------- ... ---------- -------------------------------------------------------------------------
2626
1.73905237267071 NaN ... 1998-11-13 coralie98/DRS-3.3/reduced/1998-11-13/CORALIE.1998-11-14T07:42:28.001.fits

docs/eso/eso.rst

Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ list of available instrument-specific queries can be obtained with the
109109

110110
>>> from astroquery.eso import Eso
111111
>>> eso = Eso()
112-
>>> eso.list_instruments()
112+
>>> eso.list_instruments()
113113
['fors1', 'fors2', 'sphere', 'vimos', 'omegacam', 'hawki', 'isaac', 'naco', 'visir',
114114
'vircam', 'apex', 'giraffe', 'uves', 'xshooter', 'espresso', 'muse', 'crires',
115115
'kmos', 'sinfoni', 'amber', 'gravity', 'matisse', 'midi', 'pionier', 'wlgsu']
@@ -185,31 +185,24 @@ return the observation date column.
185185
>>> print(len(table))
186186
38
187187
>>> print(table.columns)
188-
<TableColumns names=('Release Date','Object','RA','DEC','Target Ra Dec','Target l b','DATE OBS','ProgId','DP.ID','OB.ID','OBS.TARG.NAME','DPR.CATG','DPR.TYPE','DPR.TECH','INS.MODE','DIMM Seeing-avg')>
188+
<TableColumns names=('Release Date','Object','RA','DEC','Target Ra Dec','Target l b','DATE OBS','Program ID','DP.ID','OB.ID','OBS.TARG.NAME','DPR.CATG','DPR.TYPE','DPR.TECH','INS.MODE','DIMM Seeing-avg')>
189189
>>> table.pprint(max_width=100)
190190
Release Date Object RA ... DPR.TECH INS.MODE DIMM Seeing-avg
191191
------------ ----------------------- ---------- ... -------------------- -------- ---------------
192-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.01]
192+
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.03]
193193
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.68 [0.01]
194194
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.68 [0.01]
195-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.01]
196-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.01]
195+
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.06]
196+
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.05]
197197
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.74 [0.01]
198-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.69 [0.01]
199-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.66 [0.01]
200-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.64 [0.01]
201-
2008-02-07 NGC4151 182.635969 ... IMAGE,WINDOW STARINTF 0.60 [0.01]
202198
... ... ... ... ... ... ...
203-
2007-02-07 TRACK,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.72 [0.01]
204-
2007-02-07 SEARCH,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.62 [0.01]
205-
2007-02-07 SEARCH,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.61 [0.01]
206-
2007-02-07 SEARCH,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.54 [0.01]
207-
2007-02-07 SEARCH,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.53 [0.01]
199+
2007-02-07 SEARCH,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.54 [0.03]
200+
2007-02-07 SEARCH,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.53 [0.04]
201+
2007-02-07 TRACK,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.51 [0.02]
202+
2007-02-07 TRACK,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.51 [0.02]
208203
2007-02-07 TRACK,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.51 [0.01]
209-
2007-02-07 TRACK,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.51 [0.01]
210-
2007-02-07 TRACK,OBJECT,DISPERSED 182.635969 ... INTERFEROMETRY STARINTF 0.51 [0.01]
211-
2007-02-07 PHOTOMETRY,OBJECT 182.635969 ... IMAGE,WINDOW,CHOPNOD STARINTF 0.54 [0.01]
212-
2007-02-07 PHOTOMETRY,OBJECT 182.635969 ... IMAGE,WINDOW,CHOPNOD STARINTF 0.54 [0.01]
204+
2007-02-07 PHOTOMETRY,OBJECT 182.635969 ... IMAGE,WINDOW,CHOPNOD STARINTF 0.54 [0.02]
205+
2007-02-07 PHOTOMETRY,OBJECT 182.635969 ... IMAGE,WINDOW,CHOPNOD STARINTF 0.54 [0.03]
213206
Length = 38 rows
214207

215208
And indeed, 38 datasets are found, and the ``DATE OBS`` column is in the result table.
@@ -375,13 +368,13 @@ would like to download datasets from an existing request, either submitted
375368
through the functions here or externally, call ``retrieve_data`` with the
376369
``request_id`` option:
377370

378-
.. doctest-skip::
371+
.. doctest-skip::
379372

380373
>>> data_files = eso.retrieve_data(table['DP.ID'][:2], request_id=999999)
381374

382375
The ``request_id`` can be found in the automatic email sent by the archive after
383376
staging the initial request, i.e., https://dataportal.eso.org/rh/requests/[USERNAME]/{request_id}.
384-
A summary of your available requests is shown at https://dataportal.eso.org/rh/requests/[USERNAME]/recentRequests.
377+
A summary of your available requests is shown at https://dataportal.eso.org/rh/requests/[USERNAME]/recentRequests.
385378

386379
Note: The function does check that the specified retrieval URL based on
387380
``request_id`` is valid and then that the datasets indicated there are

docs/jplsbdb/jplsbdb.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ item:
156156
.. code-block:: python
157157
158158
>>> sbdb['orbit']['moid_jup'] # doctest: +REMOTE_DATA
159-
<Quantity 0.435 AU>
159+
<Quantity 0.433 AU>
160160
161161
Note that many of the items in the output dictionary are associated
162162
with `~astropy.units` which can be readily used for
@@ -167,7 +167,7 @@ orbit intersection distance of the target with respect to Jupiter
167167
.. code-block:: python
168168
169169
>>> print(sbdb['orbit']['moid_jup'].to('km')) # doctest: +REMOTE_DATA
170-
65075073.754499994 km
170+
64775878.01309999 km
171171
172172
The vast majority of parameter names are identical to those used in
173173
the `SBDB API documentation

0 commit comments

Comments
 (0)