Skip to content

Conversation

@gammazero
Copy link
Contributor

@gammazero gammazero commented Nov 20, 2025

Add the ability to explicitly set the response emitter encoding type.

This is used to set the encoding type of the response emitter to something other than the default. For example, when setting the encoding type to Gzip when compressed output is being emitted.

Needed for: ipfs/kubo#2376

I do not know if this is the right way to do this, but testing with kubo PR above indicates it does work.

TODO: add unit test to check HTTP headers

Add the ability to explicitly set the response emitter encoding type.

This is used to set the encoding type of the response emitter to something other than the default. For example, when setting the encoding type to `Gzip` when compressed output is being emitted.

Needed for: ipfs/kubo#2376
@gammazero gammazero marked this pull request as ready for review December 1, 2025 17:55
@gammazero gammazero added the need/triage Needs initial labeling and prioritization label Dec 1, 2025
},
Gzip: func(req *Request) func(io.Writer) Encoder {
return func(w io.Writer) Encoder { return TextEncoder{w: w} }
},
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Mayme we should also add a Tar item here also?

@gammazero gammazero requested a review from lidel December 2, 2025 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

need/triage Needs initial labeling and prioritization

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants