-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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 exception when display_expand_data=False for file-backed array. #5235
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for the follow-up, @tomwhite, this looks great. However, I would remove the difference between expanded and collapsed for MemoryCachedArray
since it's always a single line (see the inline comments below).
Co-authored-by: keewis <keewis@users.noreply.github.com>
Co-authored-by: keewis <keewis@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
apparently, the memory cached array has to be bigger than 1e5
to be displayed as [xyz values with dtype=DTYPE]
, so we can either keep the test as is or increase the size. Not sure which is better, but in any case, the repr
still is a single line. Thoughts, @pydata/xarray?
If we decide that we don't need to check for the repr
for bigger arrays, this can be merged as soon as we stop loading the data into memory.
once we get the CI to pass, this should be ready for merging. Just note that I'm not entirely sure about the size of the test array. |
This is now passing. We could add more tests or even change the representation a little in some cases, but it would be good to merge for the release (since it fixes a bug) if it looks OK to you @keewis. |
I agree, this looks ready. We classified this as a release blocker so it will definitely be part of the release. Before merging I'd like to have another maintainer look over this, though, to check my decisions. |
* upstream/master: (23 commits) combine keep_attrs and combine_attrs in apply_ufunc (pydata#5041) Explained what a deprecation cycle is (pydata#5289) Code cleanup (pydata#5234) FacetGrid docstrings (pydata#5293) Add whats new for dataset interpolation with non-numerics (pydata#5297) Allow dataset interpolation with different datatypes (pydata#5008) Flexible indexes: add Index base class and xindexes properties (pydata#5102) pre-commit: autoupdate hook versions (pydata#5280) convert the examples for apply_ufunc to doctest (pydata#5279) fix the new whatsnew section Ensure `HighLevelGraph` layers are `Layer` instances (pydata#5271) New whatsnew section Release-workflow: Bug fix (pydata#5273) more maintenance on whats-new.rst (pydata#5272) v0.18.0 release highlights (pydata#5266) Fix exception when display_expand_data=False for file-backed array. (pydata#5235) Warn ignored keep attrs (pydata#5265) Disable workflows on forks (pydata#5267) fix the built wheel test (pydata#5270) pypi upload workflow maintenance (pydata#5269) ...
pre-commit run --all-files
See discussion in #5126 (review)