python-hyper / python-hyper/brotlicffi
`Decompressor` uses inexistent dictionary API
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 154
- Forks
- 34
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 3
Description
While I was working on #207, I noticed that the decompressor class allows passing a custom dictionary, but the functionality is not working because lib.BrotliDecoderSetCustomDictionary was dropped since v1.0.9.0.
AttributeError: cffi library '_brotlicffi' has no function, constant or global variable named 'BrotliDecoderSetCustomDictionary'. Did you mean: 'BrotliDecoderAttachDictionary'?
It may be possible to use BrotliDecoderAttachDictionary instead of BrotliDecoderSetCustomDictionary.
This functionality has been broken for a few releases, so I hope it doesn't block releasing v1.2.0.0.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in src/brotlicffi/_api.py around lines 369-376, where Decompressor calls the removed BrotliDecoderSetCustomDictionary symbol. Read the current BrotliDecoderAttachDictionary API and its surrounding bindings, then verify that custom-dictionary decompression works without the AttributeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100