indygreg / indygreg/python-zstandard

FAILED tests/test_module_attributes.py::TestModuleAttributes::test_features fails with --system-zstd

Open
#191 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
642
Forks
116
Avg merge
1d 14h
Merged PRs (30d)
5

Description

```
python3 setup.py test --system-zstd
...
self =

def test_features(self):
self.assertIsInstance(zstd.backend_features, set)

expected = {
"cext": {
"buffer_types",
"multi_compress_to_buffer",
"multi_decompress_to_buffer",
},
"cffi": set(),
"rust": {
"buffer_types",
"multi_compress_to_buffer",
"multi_decompress_to_buffer",
},
}[zstd.backend]

> self.assertEqual(zstd.backend_features, expected)
E AssertionError: Items in the second set but not the first:
E 'multi_compress_to_buffer'
E 'multi_decompress_to_buffer'

tests/test_module_attributes.py:29: AssertionError
```

I guess the tested features are available only with a statically linked copy of libzstd, right? The tests should reflect that.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with tests/test_module_attributes.py::TestModuleAttributes::test_features and reproduce the failure using `python3 setup.py test --system-zstd`. Compare the reported backend features with the system-zstd configuration, then update the test expectations so they match supported features and confirm the test suite passes.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, python
Domain
testing-qa
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.