Repository navigation
test(v2): ignore numcodecs' Pickle deprecation warning in pickle tests - #4680
Merged
d-v-b merged 1 commit intoDec 1, 2026
Merged
Conversation
numcodecs main now warns that its Pickle codec is deprecated whenever one is created, and the suite turns warnings into errors, so the pickle decode-gate tests in test_v2.py fail in the upstream-dependencies job. Those tests create Pickle codecs on purpose, so ignore that warning for them. Released numcodecs doesn't warn, so the filter ignores the warning rather than requiring it. Assisted-by: ClaudeCode:claude-opus-5-5
d-v-b
added a commit
to d-v-b/zarr-python
that referenced
this pull request
Dec 1, 2026
…opers#4680 Assisted-by: ClaudeCode:claude-opus-5-5
d-v-b
marked this pull request as ready for review
December 1, 2026 10:23
d-v-b
added a commit
that referenced
this pull request
Dec 4, 2026
* chore(mypy): remove the no-op strict = false override mypy applies `strict` only when it is true, so `strict = false` in a per-module override is ignored. The 14 entries listed there (modules and globs) were already checked strictly. Remove the block, and reword the TODO on the `ignore_errors` list that pointed at it. Assisted-by: ClaudeCode:claude-opus-5-5 * test(fsspec): take test_fsspec off the mypy ignore list Narrow the subgroup returned by `AsyncGroup.getitem` to `AsyncGroup` before calling `group_keys`, which was the module's only mypy error, and remove `tests.test_store.test_fsspec` from the `ignore_errors` list so the module's own code is type-checked like the rest of the tests. Assisted-by: ClaudeCode:claude-opus-5-5 * test(v2): ignore numcodecs' Pickle deprecation warning in pickle tests numcodecs main now warns that its Pickle codec is deprecated whenever one is created, and the suite turns warnings into errors, so the pickle decode-gate tests in test_v2.py fail in the upstream-dependencies job. Those tests create Pickle codecs on purpose, so ignore that warning for them. Released numcodecs doesn't warn, so the filter ignores the warning rather than requiring it. Assisted-by: ClaudeCode:claude-opus-5-5 * test(fsspec): use get_group instead of narrowing getitem's result `AsyncGroup.get_group` returns an `AsyncGroup` and raises if the member is an array, so the test needs no isinstance assert to type-check. Assisted-by: ClaudeCode:claude-opus-5-5 * test(v2): match the Pickle deprecation comment to upstream #4680 Assisted-by: ClaudeCode:claude-opus-5-5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
the pickle codec is now deprecated in
numcodecs, so we handle the deprecation in our tests against numcodecs main.🤖 AI text below 🤖
Fixes the
py=3.15-upstreamtest job, which has failed since zarr-developers/numcodecs#905 made numcodecs warn whenever aPicklecodec is created. The pickle decode-gate tests intests/test_v2.pycreatePicklecodecs on purpose, so they now ignore that one deprecation warning.Details
test_pickle_codec_*tests (four tests, plus both cases of the env-var test). The suite turns warnings into errors.filterwarningsmark,ignore:The Pickle codec is deprecated:DeprecationWarning, applied only to the tests that create aPicklecodec.test_pickle_opt_in_does_not_affect_other_codecscreates none and stays unmarked. The filter ignores the warning rather than requiring it, because released numcodecs (0.17.1 and earlier) doesn't emit it, and the jobs pinned to released numcodecs should keep passing.skip_file_prefixes, so the warning is attributed to the caller (zarr/registry.pyor the test file), not to numcodecs.Pickle.__init__to emit Bump pymongo from 3.12.1 to 4.0.1 #905's warning with the same message andskip_file_prefixes.tests/test_v2.pypasses with it (35 passed).Pickle.src/never constructs one. Docs, examples andzarr.testingstrategies don't either.Adversarial review record
One round by a fresh reviewer agent, given only the diff and the files. It found nothing serious.
Pickle"in newer releases", but no release has it yet. Fixed: the comment now cites numcodecs#905 and makes no claim about releases.Picklein 0.19.0, the module-levelfrom numcodecs import ... Picklewill stop the whole oftest_v2.pyfrom collecting. Moving the pickle tests into their own module would contain that, and would let onepytestmarkreplace the per-test marks.pytest.warnswould have to read private numcodecs state, and a global ini filter would be broader than needed.DeprecationWarningthat isn't raised from__main__.upstreamhatch env pins Python 3.14, so the job namedpy=3.15-upstreamruns 3.14.🤖 Generated with Claude Code