bpo-45453: Fix test_embed.StdPrinterTests by vstinner · Pull Request #28916 · python/cpython · GitHub
Skip to content

bpo-45453: Fix test_embed.StdPrinterTests - #28916

Merged
vstinner merged 1 commit into
python:mainfrom
vstinner:test_embed
Oct 13, 2021
Merged

vstinner merged 1 commit into
python:mainfrom
vstinner:test_embed

Conversation

@vstinner

@vstinner vstinner commented Oct 13, 2021

Copy link
Copy Markdown
Member

test_embed.StdPrinterTests now always use the file descriptor 1 for
stdout, rather than using sys.stdout.fileno().
PyFile_NewStdPrinter() does crash if the parameter is not 1 or 2.

Fix also a few pyflakes warnings: remove unused import and variables.

https://bugs.python.org/issue45453

test_embed.StdPrinterTests now always use the file descriptor 1 for
stdout, rather than using sys.__stdout__.fileno().
PyFile_NewStdPrinter() does crash if the parameter is not 1 or 2.

Fix also a few pyflakes warnings: remove unused import and variables.
@bedevere-bot bedevere-bot added the tests Tests in the Lib/test dir label Oct 13, 2021
@vstinner
vstinner merged commit 678433f into python:main Oct 13, 2021
@miss-islington

Copy link
Copy Markdown
Contributor

@vstinner
vstinner deleted the test_embed branch October 13, 2021 03:24
@bedevere-bot

Copy link
Copy Markdown

@bedevere-bot bedevere-bot removed the needs backport to 3.10 only security fixes label Oct 13, 2021
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 13, 2021
test_embed.StdPrinterTests now always use the file descriptor 1 for
stdout, rather than using sys.__stdout__.fileno().
PyFile_NewStdPrinter() does crash if the argument is not 1 or 2.

Fix also a few pyflakes warnings: remove unused import and variables.
(cherry picked from commit 678433f)

Co-authored-by: Victor Stinner <vstinner@python.org>
vstinner added a commit that referenced this pull request Oct 13, 2021
test_embed.StdPrinterTests now always use the file descriptor 1 for
stdout, rather than using sys.__stdout__.fileno().
PyFile_NewStdPrinter() does crash if the argument is not 1 or 2.

Fix also a few pyflakes warnings: remove unused import and variables.
(cherry picked from commit 678433f)

Co-authored-by: Victor Stinner <vstinner@python.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip news tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants