Skip to content

Clarify max_length in zstd/zlib decompression documentation#143805

Open
Dreamsorcerer wants to merge 4 commits intopython:mainfrom
Dreamsorcerer:patch-10
Open

Clarify max_length in zstd/zlib decompression documentation#143805
Dreamsorcerer wants to merge 4 commits intopython:mainfrom
Dreamsorcerer:patch-10

Conversation

@Dreamsorcerer
Copy link
Copy Markdown
Contributor

@Dreamsorcerer Dreamsorcerer commented Jan 13, 2026

It's not that obvious from the docs today how to actually read the full output from compressed data when using the max_length parameter (zstd doesn't even mention the requirement to check .eof).


📚 Documentation preview 📚: https://cpython-previews--143805.org.readthedocs.build/

@picnixz picnixz changed the title Improve compression max_length documentation Improve compression max_length documentation Mar 7, 2026
@picnixz picnixz changed the title Improve compression max_length documentation Improve zlib compression max_length documentation Mar 7, 2026
@picnixz picnixz changed the title Improve zlib compression max_length documentation Clarify max_length in zstd/zlib decompression documentation Mar 7, 2026
@picnixz
Copy link
Copy Markdown
Member

picnixz commented Mar 7, 2026

(Sorry, I struggled to find the correct title :'))

Copy link
Copy Markdown
Member

@emmatyping emmatyping left a comment

Choose a reason for hiding this comment

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

Thanks for catching the missing docs for compression.zstd!

I think the zlib doc change isn't correct however, so please remove it.

@bedevere-app
Copy link
Copy Markdown

bedevere-app bot commented Mar 10, 2026

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@Dreamsorcerer
Copy link
Copy Markdown
Contributor Author

I have made the requested changes; please review again

@bedevere-app
Copy link
Copy Markdown

bedevere-app bot commented Mar 17, 2026

Thanks for making the requested changes!

@emmatyping: please review the changes made to this pull request.

@emmatyping
Copy link
Copy Markdown
Member

Sorry, I'll take a look at this this weekend.

@Dreamsorcerer
Copy link
Copy Markdown
Contributor Author

I also opened a discussion here about improving the actual API:
https://discuss.python.org/t/zlib-decompress-should-have-an-attribute-to-tell-if-output-is-available/106898

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

4 participants