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

process_test: Remove compatibility hack for python 3.13 beta 1 #3395

Merged
merged 1 commit into from
Jun 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
tox_env: py311-full
- python: '3.12.0'
tox_env: py312-full
- python: '3.13.0-beta.1 - 3.13'
- python: '3.13.0-beta.2 - 3.13'
# Some optional dependencies don't seem to work on 3.13 yet
tox_env: py313
- python: 'pypy-3.8'
Expand Down
11 changes: 0 additions & 11 deletions tornado/test/process_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,19 +140,11 @@ def term_and_wait(self, subproc):

@gen_test
def test_subprocess(self):
# In Python 3.13.0b1, the new repl logs an error on exit if terminfo
# doesn't exist, the -i flag is used, and stdin is not a tty. This bug may
# have been fixed in beta 2, so for now we disable the new repl in this test
# and the next. Once we've tested with beta 2 we can either remove this env var
# or file a bug upstream if it still exists.
env = dict(os.environ)
env["PYTHON_BASIC_REPL"] = "1"
subproc = Subprocess(
[sys.executable, "-u", "-i"],
stdin=Subprocess.STREAM,
stdout=Subprocess.STREAM,
stderr=subprocess.STDOUT,
env=env,
)
self.addCleanup(lambda: self.term_and_wait(subproc))
self.addCleanup(subproc.stdout.close)
Expand All @@ -170,14 +162,11 @@ def test_subprocess(self):
@gen_test
def test_close_stdin(self):
# Close the parent's stdin handle and see that the child recognizes it.
env = dict(os.environ)
env["PYTHON_BASIC_REPL"] = "1"
subproc = Subprocess(
[sys.executable, "-u", "-i"],
stdin=Subprocess.STREAM,
stdout=Subprocess.STREAM,
stderr=subprocess.STDOUT,
env=env,
)
self.addCleanup(lambda: self.term_and_wait(subproc))
yield subproc.stdout.read_until(b">>> ")
Expand Down