-
-
Notifications
You must be signed in to change notification settings - Fork 358
Fix JSON encoding of complex fill values #2432
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 JSON encoding of complex fill values #2432
Conversation
We were not replacing NaNs and Infs with the string versions.
store = MemoryStore({}, mode="w") | ||
Array.create(store=store, shape=(1,), dtype=np.complex64, fill_value=fill_value) | ||
content = await store.get("zarr.json", prototype=default_buffer_prototype()) | ||
assert content is not None |
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.
won't we get an error later in the test if content
is None
? or is this just for mypy (in which case I'd prefer explicitly ignore the type error)?
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.
It is for mypy.
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.
that store.get
can return None
is an unfortunate part of our store API that we need to fix IMO...
We were not replacing NaNs and Infs with the string versions.
[Description of PR]
TODO: