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

Silence hypothesis complex warning #2157

Open
wants to merge 8 commits into
base: v3
Choose a base branch
from

Conversation

dcherian
Copy link
Contributor

@dcherian dcherian commented Sep 8, 2024

Closes #2155

[Description of PR]

TODO:

  • Add unit tests and/or doctests in docstrings
  • Add docstrings and API docs for any new/modified user-facing classes and functions
  • New/modified features documented in docs/tutorial.rst
  • Changes documented in docs/release.rst
  • GitHub Actions have all passed
  • Test coverage is 100% (Codecov passes)

@dcherian dcherian force-pushed the fix-hypothesis-complex-warning branch from c55ffa4 to 4a8fca0 Compare September 8, 2024 23:16
@dcherian dcherian force-pushed the fix-hypothesis-complex-warning branch from 4a8fca0 to eeaea6a Compare September 8, 2024 23:16
Copy link
Contributor

@dstansby dstansby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to mark as request changes so this doesn't get merged before https://github.com/zarr-developers/zarr-python/pull/2157/files#r1757019017 is discussed. Given this is public API I think we should at least document the behaviour, and possibly add a equal_nan keyword argument to signal that the behaviour is different to default numpy behaviour. (or I guess make it private API...)

@jhamman jhamman added the V3 Related to compatibility with V3 spec label Sep 13, 2024
* v3:
  fix: opening a group with unspecified format finds either v2 or v3 (zarr-developers#2183)
  test: check that store, array, and group classes are serializable  (zarr-developers#2006)
  feature(store): V3 ZipStore (zarr-developers#2078)
  More typing fixes for tests (zarr-developers#2173)
  refactor: split metadata into v2 and v3 modules (zarr-developers#2163)
  Accept dictionaries for `store` argument (zarr-developers#2164)
  Simplify mypy config for tests (zarr-developers#2156)
  Fixed path segment duplication in open_array (zarr-developers#2167)
  Fixed test warnings (zarr-developers#2168)
  chore: update pre-commit hooks (zarr-developers#2165)
  Ensure that store_dict used for empty dicts (zarr-developers#2162)
  Bump pypa/gh-action-pypi-publish from 1.10.0 to 1.10.1 in the actions group (zarr-developers#2160)
assert np.isnan(arr.fill_value)
assert arr.fill_value.dtype == arr.dtype
# all fill value chunk is an empty chunk, and should not be written
assert not [a async for a in store.list_prefix("/")]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
assert not [a async for a in store.list_prefix("/")]
assert len([a async for a in store.list_prefix("/")]) == 0

I think makes it clearer that the check is for zero chunks written?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
V3 Related to compatibility with V3 spec
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

Hyptohesis test failure
4 participants