-
-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Debug output for Logic side effects #447
Comments
This would be nice to be put into the Gt\WebEngine\Debug namespace, as we already have one with just the Timer class. |
Now anything echoed to the page is output as a |
Follows on from #299 |
Current implementation is nearly completed. The RequestHandler::handleLogicExecution is storing the buffer correctly in the Lifecycle's debugOutput array, but still to do is understand which file's go/do functions are the trigger of the buffer. This could be done by converting LogicExecutor::invoke to a Generator function: the generator can yield a filename each time it executes the function, allowing the RequestHandler to iterate over the invoke call, adding the output buffer to the correct debug stream. |
Logic classes should have no side effect. If they do, for example by echoing something, webengine should throw an exceptionIf anything is output to the buffer before the Lifecycle::finish function is called, this should be collected and output into a special debug area of the page.
Would it be nice to put it in the JavaScript console, instead of directly into the HTML? Probably...
The text was updated successfully, but these errors were encountered: