Skip to content

[3.8] bpo-1812: Fix newline conversion when doctest.testfile loads from a package whose loader has a get_data method (GH-17385) #19175

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

Merged
merged 1 commit into from
Mar 26, 2020

Conversation

miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Mar 26, 2020

This pull request fixes the newline conversion bug originally reported in bpo-1812. When that issue was originally submitted, the open builtin did not default to universal newline mode; now it does, which makes the issue fix simpler, since the only code path that needs to be changed is the one in doctest._load_testfile where the file is loaded from a package whose loader has a get_data method.
(cherry picked from commit e0b8101)

Co-authored-by: Peter Donis [email protected]

https://bugs.python.org/issue1812

…ackage whose loader has a get_data method (pythonGH-17385)

This pull request fixes the newline conversion bug originally reported in bpo-1812. When that issue was originally submitted, the open builtin did not default to universal newline mode; now it does, which makes the issue fix simpler, since the only code path that needs to be changed is the one in doctest._load_testfile where the file is loaded from a package whose loader has a get_data method.
(cherry picked from commit e0b8101)

Co-authored-by: Peter Donis <[email protected]>
@miss-islington
Copy link
Contributor Author

@pdonis and @zware: Status check is done, and it's a success ✅ .

@miss-islington miss-islington merged commit b05fbe9 into python:3.8 Mar 26, 2020
@miss-islington miss-islington deleted the backport-e0b8101-3.8 branch March 26, 2020 16:18
@miss-islington
Copy link
Contributor Author

@pdonis and @zware: Status check is done, and it's a success ✅ .

1 similar comment
@miss-islington
Copy link
Contributor Author

@pdonis and @zware: Status check is done, and it's a success ✅ .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants