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

Do not apply line endings twice. (#671) #672

Merged
merged 1 commit into from
Feb 12, 2018
Merged

Do not apply line endings twice. (#671) #672

merged 1 commit into from
Feb 12, 2018

Conversation

jchv
Copy link
Contributor

@jchv jchv commented Feb 11, 2018

At least on some occasions, setting newline to whatever the line endings currently are can cause Python to replace the \ns with whatever you pass in, causing lines to be encoded twice. This leads to CRLF files containing \r\r\n sequences in place of \r\n.

Fixes issue #671.

At least on some occasions, setting `newline` to whatever the line endings currently are can cause Python to replace the `\n`s with whatever you pass in, causing lines to be encoded twice. This leads to CRLF files containing `\r\r\n` sequences in place of `\r\n`.
@timothycrosley
Copy link
Member

Looks good, thank you!

@timothycrosley timothycrosley merged commit 64f9631 into PyCQA:develop Feb 12, 2018
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