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

[String Response] Respect remote server's content encoding #359

Closed
wants to merge 1 commit into from
Closed

[String Response] Respect remote server's content encoding #359

wants to merge 1 commit into from

Conversation

kylef
Copy link
Contributor

@kylef kylef commented Feb 24, 2015

We should always follow the content encoding sent from the server instead of assuming UTF-8 or whatever the user has configured.

Note, iso-8859-1 is the default encoding for HTTP 1.1. As such that is the default if a server didn't explicitly set it to utf-8.

@kylef kylef changed the title [String Response] Follow the server's content encoding [String Response] Respect remote server's content encoding Feb 27, 2015
mattt added a commit that referenced this pull request Apr 9, 2015
…ith overrideable configuration, defaulting string response serialization to ISO-8859-1, as per the HTTP/1.1 specification.
@mattt
Copy link
Sponsor Contributor

mattt commented Apr 9, 2015

Thanks for your PR, @kylef. I really appreciate you following up on #358 to find the underlying problem here.

We should definitely respect the server's character encoding, when provided. We should definitely follow the spec to use ISO-8859-1 by default. However, we should also provide a way to override this behavior for when the server is doing something wrong, and it's not possible to fix.

I implemented this with 6cffddc, which should resolve the original issues. Let me know if I missed anything here.

Thanks again, @kylef.

@mattt mattt closed this Apr 9, 2015
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.

None yet

2 participants