Skip to content
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

Fix Content-Length header when compressing gzip #1053

Merged
merged 1 commit into from
Dec 14, 2024

Conversation

keul
Copy link
Contributor

@keul keul commented Dec 10, 2024

Overview

pycsw is sending the same Content-Length header when compressing gzip or not. The problem that this lead to is not always visible, but some browsers like Chrome and Safari when using HTTP2 are truncating connections when the length header is not matching the real response.

Content-Length should always be the length of bytes sent to the client, not the length of uncompressed content.

Related Issue / Discussion

See also #954

Contributions and Licensing

(as per https://github.com/geopython/pycsw/blob/master/CONTRIBUTING.rst#contributions-and-licensing)

  • I'd like to contribute [feature X|bugfix Y|docs|something else] to pycsw. I confirm that my contributions to pycsw will be compatible with the pycsw license guidelines at the time of contribution.
  • I have already previously agreed to the pycsw Contributions and Licensing Guidelines

@tomkralidis tomkralidis merged commit 392e02a into geopython:master Dec 14, 2024
3 checks passed
@tomkralidis tomkralidis added this to the 3.0.0 milestone Dec 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants