Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix NamedArray html repr crashing #9553

Merged
merged 3 commits into from
Sep 27, 2024
Merged

Conversation

Illviljan
Copy link
Contributor

@Illviljan Illviljan commented Sep 27, 2024

This crashes on main:

import numpy as np
from xarray.namedarray.core import NamedArray

x = NamedArray(("x",), np.array([1, 2, 3]))
x._repr_html_()
#   File ~\Documents\GitHub\xarray\xarray\core\formatting.py:306 in inline_variable_array_repr
#     if var._in_memory:

# AttributeError: 'NamedArray' object has no attribute '_in_memory'

@Illviljan Illviljan enabled auto-merge (squash) September 27, 2024 18:00
@Illviljan Illviljan merged commit cde720f into pydata:main Sep 27, 2024
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants