compatibility astropy units non standard
in tools/fits.py, this
try:
dsthdr['BUNIT'] = (unit.to_string('fits'), 'data unit type')
except u.format.fits.UnitScaleError:
dsthdr['BUNIT'] = (fix_unit_write(str(unit)), 'data unit type')
should be
try:
dsthdr['BUNIT'] = (unit.to_string('fits'), 'data unit type')
except:
dsthdr['BUNIT'] = (fix_unit_write(str(unit)), 'data unit type')