Version
v2026.7.0
How did you install UXarray?
Source
What happened?
UxDataset and UxDataArray currently allow uxgrid=None, but their docstrings say "If None, it needs to be an instance of uxarray.Grid." I'm not really sure what that is supposed to mean.
Additionally, using uxgrid=None leads to confusing errors later, such as AttributeError: 'NoneType' object has no attribute 'n_face'. It would be much easier to debug an error like TypeError: UxDataArray.__init__() missing one required argument: 'uxgrid' instead.
What did you expect to happen?
I expected instantiating UxDataset and UxDataArray to fail if uxgrid is not provided.
Or, I expected a docstring which correctly clarifies what happens if uxgrid is None, perhaps providing at least one example use-case clarifying why uxgrid=None is supported?
Can you provide a MCVE to repoduce the bug?
Version
v2026.7.0
How did you install UXarray?
Source
What happened?
UxDataset and UxDataArray currently allow uxgrid=None, but their docstrings say "If
None, it needs to be an instance ofuxarray.Grid." I'm not really sure what that is supposed to mean.Additionally, using uxgrid=None leads to confusing errors later, such as
AttributeError: 'NoneType' object has no attribute 'n_face'. It would be much easier to debug an error likeTypeError: UxDataArray.__init__() missing one required argument: 'uxgrid'instead.What did you expect to happen?
I expected instantiating UxDataset and UxDataArray to fail if uxgrid is not provided.
Or, I expected a docstring which correctly clarifies what happens if uxgrid is None, perhaps providing at least one example use-case clarifying why uxgrid=None is supported?
Can you provide a MCVE to repoduce the bug?