gh-76785: Fixes for test.support.interpreters (gh-112982)

This involves a number of changes for PEP 734.
This commit is contained in:
Eric Snow 2023-12-12 08:24:31 -07:00 committed by GitHub
parent f26bfe4b25
commit 86a77f4e1a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
30 changed files with 2506 additions and 1507 deletions

View file

@ -79,8 +79,7 @@ class Interpreter(namedtuple('Interpreter', 'name id')):
name = 'interp'
elif name == 'main':
raise ValueError('name mismatch (unexpected "main")')
if not isinstance(id, interpreters.InterpreterID):
id = interpreters.InterpreterID(id)
assert isinstance(id, int), repr(id)
elif not name or name == 'main':
name = 'main'
id = main