Skip to content

Commit 013261c

Browse files
authored
Merge pull request #3139 from cds-astro/mocserver
Partial rewrite of the MOCServer module
2 parents 1944001 + 0bed33f commit 013261c

File tree

13 files changed

+1597
-923
lines changed

13 files changed

+1597
-923
lines changed

CHANGES.rst

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,42 @@ jplspec
1919

2020
- minor improvement to lookuptable behavior [#3173,#2901]
2121

22+
mocserver
23+
^^^^^^^^^
24+
25+
- Switch to https instead of http for the default url (allows pyodide to use the
26+
module) [#3139]
27+
28+
- Add ``TimeMOC`` and ``STMOC`` as possible entries in ``MOCServer.query_region`` to
29+
allow temporal and space-time searches [#3139]
30+
31+
- ``return_moc`` now allows to ask for a Time-MOC or a Space-Time MOC rather than only
32+
Space-MOCs [#3139]
33+
34+
- Fix query by MOC that would write a file ``moc.fits`` where the method was executed in
35+
overwriting mode (potentially deleting data if there was a conflicting file) [#3139]
36+
37+
- [:warning: BREAKING] Returned tables now have a default list of fields instead of the
38+
> 130 columns returned previously. The full list of fields can be displayed with the
39+
new method ``MOCServer.list_fields`` [#3139]
40+
41+
- Add ``casesensitive`` parameter in the queries (previously, this was hardcoded
42+
to ``True``) [#3139]
43+
44+
- Add ``coordinate_system`` parameter to the queries to allow to filter on the different
45+
bodies or frames. The list of available space systems can be printed with the new
46+
method ``MOCServer.list_coordinates_systems`` [#3139]
47+
48+
- Add ``query_hips`` method, which is convenient to filter only Hierarchical progressive
49+
surveys [#3139]
50+
51+
- New parameter ``criteria`` in ``query_region`` and ``query_hips`` that has the same
52+
use than ``meta_data`` in the deprecated method ``find_datasets`` [#3139]
53+
2254
simbad
2355
^^^^^^
2456

25-
- Fixed adding a list of fluxes with the deprecated notation
57+
- Fixed adding a list of fluxes with the deprecated notation
2658
``Simbad.add_votable_fields("flux(U)", "flux(J)")`` [#3186]
2759

2860
- Support more of the 0.4.7 votable fields. Raise more significant error messages
@@ -32,6 +64,7 @@ simbad
3264

3365
- Fixed non existing flux filters as votable fields would fail silently [#3186]
3466

67+
3568
Infrastructure, Utility and Other Changes and Additions
3669
-------------------------------------------------------
3770

astroquery/mocserver/__init__.py

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# Licensed under a 3-clause BSD style license - see LICENSE.rst
2-
"""
3-
CDS MOCServer Query Tool
4-
------------------------
2+
"""CDS MOCServer Query Tool.
3+
----------------------------
54
65
:Author: Matthieu Baumann ([email protected])
76
@@ -13,8 +12,9 @@
1312
Note: If the access to MOCs with the MOCServer tool was helpful for your research,
1413
the following acknowledgment would be appreciated::
1514
16-
This research has made use of the MOCServer, a tool developed at CDS, Strasbourg, France aiming at retrieving
17-
MOCs/meta-data from known data-sets. MOC is an IVOA standard described in the following paper :
15+
This research has made use of the MOCServer, a tool developed at CDS, Strasbourg,
16+
France aiming at retrieving MOCs/meta-data from known data-sets. MOC is an IVOA
17+
standard described in :
1818
http://www.ivoa.net/documents/MOC/20140602/REC-MOC-1.0-20140602.pdf
1919
"""
2020

@@ -24,14 +24,12 @@
2424

2525

2626
class Conf(_config.ConfigNamespace):
27-
"""
28-
Configuration parameters for ``astroquery.template_module``.
29-
"""
27+
"""Configuration parameters for ``astroquery.template_module``."""
3028

3129
server = _config.ConfigItem(
3230
[
33-
"http://alasky.unistra.fr/MocServer/query",
34-
"http://alaskybis.unistra.fr/MocServer/query",
31+
"https://alasky.unistra.fr/MocServer/query",
32+
"https://alaskybis.unistra.fr/MocServer/query",
3533
],
3634
"Name of the template_module server to use.",
3735
)
@@ -40,6 +38,16 @@ class Conf(_config.ConfigNamespace):
4038
30, "Time limit for connecting to template_module server."
4139
)
4240

41+
default_fields = [
42+
"ID",
43+
"obs_title",
44+
"obs_description",
45+
"nb_rows",
46+
"obs_regime",
47+
"bib_reference",
48+
"dataproduct_type",
49+
]
50+
4351

4452
conf = Conf()
4553

0 commit comments

Comments
 (0)