Closed astrojuanlu closed 6 years ago
In fact, if I try to run those tests locally, all of the remote tests fail:
$ python setup.py test --package='jplhorizons' --remote-data='any'
[...]
============================= test session starts =============================
platform linux -- Python 3.6.4, pytest-3.5.1, py-1.5.3, pluggy-0.6.0
Running tests with astroquery version 0.3.8.
Running tests in astroquery/jplhorizons docs/jplhorizons.
Date: 2018-07-12T11:52:23
Platform: Linux-4.15.0-24-generic-x86_64-with-debian-stretch-sid
Executable: /home/juanlu/.miniconda36/envs/poliastro36/bin/python
Full Python Version:
3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 18:10:19)
[GCC 7.2.0]
encodings: sys: utf-8, locale: UTF-8, filesystem: utf-8
byteorder: little
float info: dig: 15, mant_dig: 15
Numpy: 1.14.3
Matplotlib: 2.2.2
Pandas: 0.22.0
Astropy: 3.0.2
APLpy: not available
pyregion: not available
Using Astropy options: remote_data: any.
rootdir: /tmp/astroquery-test-xh4rw1wf/lib/python3.6/site-packages, inifile: setup.cfg
plugins: remotedata-0.3.0, openfiles-0.3.0, doctestplus-0.1.3, cov-2.5.1, arraydiff-0.2
collected 22 items
astroquery/jplhorizons/core.py ..... [ 22%]
astroquery/jplhorizons/tests/test_jplhorizons.py ... [ 36%]
astroquery/jplhorizons/tests/test_jplhorizons_remote.py FFFF.FF.FF.FF [ 95%]
docs/jplhorizons/jplhorizons.rst . [100%]
================================== FAILURES ===================================
[...]
cc @mommermi @mkelley
While I wait for the release, I saw that I can do
from astroquery.jplhorizons import conf
conf.horizons_server = 'https://ssd.jpl.nasa.gov/horizons_batch.cgi'
Horizons(...)
and everything works. This was not very well documented though, so perhaps it's not the way it should be used.
No, that's totally a valid way to change the configuration. It doesn't make much sense do change those defaults for most of the modules, but I guess some generic docs wouldn't hurt anyway. I'm just not sure about the location, I guess not many users are looking into e.g. https://astroquery.readthedocs.io/en/latest/api.html?
I reached that document, and seemed like dev documentation to me. My two cents :)
Ran into this issue again, thanks @Juanlu001 for the conf solution, worked like a charm!
@ColinOrionChandler - Which version do you use? If it's 0.3.8, you could try to switch to the latest release with pip install --update --pre astroquery
I'm trying to reproduce the Horizons examples from the documentation, but I get a
OSError: Cannot parse table column names.
no matter what I try: