Skip to content

CURLOPT_ACCEPT_ENCODING set to NULL#263

Merged
carlopi merged 1 commit into
duckdb:mainfrom
carlopi:curl_accept_encoding_null
Feb 26, 2026
Merged

CURLOPT_ACCEPT_ENCODING set to NULL#263
carlopi merged 1 commit into
duckdb:mainfrom
carlopi:curl_accept_encoding_null

Conversation

@carlopi
Copy link
Copy Markdown
Member

@carlopi carlopi commented Feb 25, 2026

Relevant documentation at https://curl.se/libcurl/c/CURLOPT_ACCEPT_ENCODING.html

I am considering whether having an option (that can be set user side), would be best here in case of regressions.

Fix was proposed by @ywelsch in the context of wider testing they performed where files uploaded to S3 like:

aws s3 cp file.json.gz s3://<bucket>/file.json.gz --content-type gzip

would be unzipped twice since information is not propagated between layers.

@carlopi carlopi merged commit 8481b55 into duckdb:main Feb 26, 2026
12 checks passed
@carlopi
Copy link
Copy Markdown
Member Author

carlopi commented Feb 26, 2026

Relevant in the context of duckdb/duckdb#20977

@rustyconover
Copy link
Copy Markdown
Contributor

Hi, this PR has caused some problems with me and I just opened an issue to re-enable cURL's support for Content-Encoding. With this change no responses are compressed with gzip/deflate and we're using more bandwidth than we need.

But even worse, if I want to handle the decompression myself in an extension, now when the server sends Content-Encoding: zstd (because I added an Accepts-Encoding header), curl rejects the response with CURLE_BAD_CONTENT_ENCODING and the entire request fails.

@rustyconover
Copy link
Copy Markdown
Contributor

PR is #278

@carlopi carlopi mentioned this pull request Mar 7, 2026
3 tasks
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