Skip to content

[3.10] bpo-14916: use specified tokenizer fd for file input (GH-31006) #31065

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
Feb 3, 2022

Conversation

miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Feb 1, 2022

@pablogsal, sorry i failed to rebase to main, so i recreated https://github.com/python/cpython/pull/22190GH-issuecomment-1024633392

PyRun_InteractiveOne*() functions allow to explicitily set fd instead of stdin.
but stdin was hardcoded in readline call.

This patch does not fix target file for prompt unlike original bpo one : prompt fd is unrelated to tokenizer source which could be read only. It is more of a bugfix regarding the docs : actual documentation say "prompt the user" so one would expect prompt to go on stdout not a file for both PyRun_InteractiveOne*() and PyRun_InteractiveLoop*().

Automerge-Triggered-By: GH:pablogsal
(cherry picked from commit 89b1304)

Co-authored-by: Paul m. p. P [email protected]

https://bugs.python.org/issue14916

@pablogsal, sorry i failed to rebase to main, so i recreated https://github.com/python/cpython/pull/22190GH-issuecomment-1024633392

> PyRun_InteractiveOne\*() functions allow to explicitily set fd instead of stdin.
but stdin was hardcoded in readline call.

> This patch does not fix target file for prompt unlike original bpo one : prompt fd is unrelated to tokenizer source which could be read only. It is more of a bugfix regarding the docs :  actual documentation say "prompt the user" so one would expect prompt to go on stdout not a file for both PyRun_InteractiveOne\*() and PyRun_InteractiveLoop\*().

Automerge-Triggered-By: GH:pablogsal
(cherry picked from commit 89b1304)

Co-authored-by: Paul m. p. P <[email protected]>
@miss-islington
Copy link
Contributor Author

@pmp-p: Status check is done, and it's a success ✅ .

@miss-islington
Copy link
Contributor Author

@pmp-p: 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
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants