Commit 5a9f4747 authored by Michael Droettboom's avatar Michael Droettboom

Only print console when done with a code chunk

parent c73c37e6
...@@ -42,7 +42,6 @@ ...@@ -42,7 +42,6 @@
term.set_prompt('[[;gray;]... ]') term.set_prompt('[[;gray;]... ]')
} else { } else {
term.set_prompt('[[;red;]>>> ]') term.set_prompt('[[;red;]>>> ]')
}
var stderr = pyodide.runPython("sys.stderr.getvalue()").trim() var stderr = pyodide.runPython("sys.stderr.getvalue()").trim()
if (stderr) { if (stderr) {
term.echo(`[[;red;]${stderr}]`) term.echo(`[[;red;]${stderr}]`)
...@@ -53,6 +52,7 @@ ...@@ -53,6 +52,7 @@
} }
} }
} }
}
term.runPython = function(code) { term.runPython = function(code) {
pyodide.runPythonAsync(code).then( pyodide.runPythonAsync(code).then(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment