Add REPL plugin hooks; Add output, output-mode, stderr attributes (#1106)

* Add before, after REPL hooks

* Re-introduce 'output-mode' attribute for py-repl

* Add plugin execution tests

* Documentation

* Changelog

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: mariana <marianameireles@protonmail.com>
This commit is contained in:
Jeff Glass
2023-03-22 20:19:22 -05:00
committed by GitHub
parent 51d51409d3
commit ef793aecf3
10 changed files with 514 additions and 91 deletions

View File

@@ -189,8 +189,9 @@ export class PyScriptApp {
this.logStatus('Initializing web components...');
// lifecycle (8)
createCustomElements(interpreter);
//Takes a runtime and a reference to the PyScriptApp (to access plugins)
createCustomElements(interpreter, this);
await initHandlers(interpreter);
// NOTE: interpreter message is used by integration tests to know that