Files
pyscript/pyscript.core/test/terminal.py
Antonio Cuni 4256a81653 run pre-commit on all files (#1789)
pre-commit.ci has been disabled for a while.
This PR ensures that all the files has been validated/formatted by pre-commit, to avoid spurious diffs in subsequent PRs.

During the process, ruff broke the code because it removed an "unused" import which was actually used.
A linter which breaks my code is a linter which I cannot trust, so I just removed it. I re-enabled isort instead.
2023-10-05 15:10:31 +02:00

15 lines
230 B
Python

###### magic monkey patching ######
import builtins
import sys
from pyodide.code import eval_code
from pyscript import sync
sys.stdout = sync
builtins.input = sync.readline
####### main code ######
import code
code.interact()