Skip to content

Error on warnings when testing #620

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

Merged
merged 6 commits into from
Nov 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:
shell: "bash -l {0}"
run: |
conda activate env
python -m pip install "zfpy>=1" "numpy<2"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is needed to avoid zfpy trying to install a very old version of numpy. Instead, by installing the extra, it respects the minimum version of numpy supported by numcodecs.

python -m pip install -v ".[zfpy]"

- name: List installed packages
shell: "bash -l {0}"
Expand Down
3 changes: 3 additions & 0 deletions numcodecs/tests/test_compat.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ def test_ensure_bytes_invalid_inputs():
ensure_bytes(e)


@pytest.mark.filterwarnings(
"ignore:The 'u' type code is deprecated and will be removed in Python 3.16"
)
def test_ensure_contiguous_ndarray_invalid_inputs():
# object array not allowed
a = np.array(['Xin chào thế giới'], dtype=object)
Expand Down
3 changes: 3 additions & 0 deletions numcodecs/tests/test_msgpacks.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ def test_backwards_compatibility():
check_backwards_compatibility(codec.codec_id, arrays, [codec])


@pytest.mark.filterwarnings(
"ignore:Creating an ndarray from ragged nested sequences .* is deprecated.*"
)
@pytest.mark.parametrize(
("input_data", "dtype"),
[
Expand Down
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,10 @@ norecursedirs = [
]
log_cli_level = "INFO"
xfail_strict = true
filterwarnings = [
"error",
]

[tool.cibuildwheel]
environment = { DISABLE_NUMCODECS_AVX2=1 }
[tool.cibuildwheel.macos]
Expand Down
Loading