You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug pysat.Instrument.empty checks the length of time or epoch coordinates if the data format is xarray. A dataset may be loaded without one of those which ensures that the Instrument always reports it is empty. This can have other downstream consequences.
To Reproduce
Steps to reproduce the behavior:
Load an xarray dataset without 'time' or 'epoch'
Check Instrument.empty
See error
Expected behavior
empty should be more robust for xarray. Unfortunately xarray does not have its own empty.
Desktop (please complete the following information):
OS: MacOS 11.5.2
Version Python 3.8
Other details about your setup that could be relevant
Additional context
pysat does have a base assumption that data is time indexed. Still, it should do a bit better when data isn't as expected, particularly since pysat doesn't complain at all!!
This bug results in no metadata being assigned. If an instrument reports empty then loaded metadata is not assigned to the Instrument.
The text was updated successfully, but these errors were encountered:
Describe the bug
pysat.Instrument.empty
checks the length oftime
orepoch
coordinates if the data format is xarray. A dataset may be loaded without one of those which ensures that the Instrument always reports it is empty. This can have other downstream consequences.To Reproduce
Steps to reproduce the behavior:
Expected behavior
empty should be more robust for xarray. Unfortunately xarray does not have its own
empty
.Desktop (please complete the following information):
Additional context
pysat does have a base assumption that data is time indexed. Still, it should do a bit better when data isn't as expected, particularly since pysat doesn't complain at all!!
This bug results in no metadata being assigned. If an instrument reports empty then loaded metadata is not assigned to the Instrument.
The text was updated successfully, but these errors were encountered: