NASA-Planetary-Science/sbpy

`sbpy.data.Phys.from_sbdb` error in processing units

jianyangli opened this issue · 2 comments

High-level problem description
sbpy.data.Phys.from_sbdb reports error when parsing units like 'kg/m^3'

What did you do?
Tried to pull the physical properties of asteroid Bennu from JPL SBDB with below lines:

from sbpy.data import Phys
p = Phys.from_sbdb('bennu')

What did you expect?
Return all physical properties available from SBDB in a sbpy.data.Phys class object.

What did really happen?
Exception:
ValueError: 'J/m^2/s^0.5/K' did not parse as unit: Syntax error parsing unit 'J/m^2/s^0.5/K' If this is meant to be a custom unit, define it with 'u.def_unit'. To have it recognized inside a file reader or other code, enable it with 'u.add_enabled_units'. For details, see https://docs.astropy.org/en/latest/units/combining_and_defining.html

Provide information on your environment:
sbpy: 0.2.3.dev191+g448afc4

hmm, probably astroquery problem. I'll investigate.

Yes it's an astroquery.jplsbdb.SBDB class problem. Close this issue here, and I'll submit an issue to astroquery.