While working on #132173 I've noticed that this error message mentions the wrong function:
>>> import _interpreters
>>> _interpreters.create()
1
>>> _interpreters.run_string(1, '')
Traceback (most recent call last):
File "<python-input-2>", line 1, in <module>
_interpreters.run_string(1, '')
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^
ValueError: _interpreters.exec(): bad script text (too short)
It should be:
>>> import _interpreters
>>> _interpreters.create()
1
>>> _interpreters.run_string(1, '')
Traceback (most recent call last):
File "<python-input-4>", line 1, in <module>
_interpreters.run_string(1, '')
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^
ValueError: _interpreters.run_string(): bad script text (too short)
I have a PR ready.
Linked PRs