riogroup / SORA

MIT License
14 stars 11 forks source link

AstropyDepreciationWarning #70

Open GianmarcoBroilo opened 2 years ago

GianmarcoBroilo commented 2 years ago

Hello everybody! I am new to SORA, I am trying to predict occultations of Io based on a paper that suggested occultations in 2019 and 2021. If I try to predict them, using this code: ` io = Body(name='Io', ephem=['/Users/gianmarcobroilo/Desktop/Tudat/SORA/input/jup365.bsp', '/Users/gianmarcobroilo/Desktop/Tudat/SORA/input/de441_part-1.bsp'])

print(io)

pred = prediction(body=io, time_beg='2019-09-09',time_end='2019-09-12',mag_lim=16)

print(pred)`

I get this issue only when it actually finds occultation possibilities: Searching occultations in part 1/1 Generating Ephemeris between 2019-09-09 00:00:00.000 and 2019-09-11 23:59:00.000 ... Downloading stars ... 65 Gaia-EDR3 stars downloaded Identifying occultations ... WARNING: AstropyDeprecationWarning: ``id_type``s 'majorbody' and 'id' are deprecated and replaced with ``None``, which has the same functionality. [astroquery.jplhorizons.core] Traceback (most recent call last):

Thank you for the help!

altairgomes commented 2 years ago

Hi @GianmarcoBroilo . This is not an error, so the code continues running without any problem.

This warning is raised due to a recent update on astroquery regarding parameters when calling jplhorizons. But the current parameters work just fine. This will be a simple modification in SORA to fix it, but it will take some time until a release is made.

You can just ignore this warning.

I know the printing of many warning may bother, so I will try to provide you a script to safely ignore it.