-
Notifications
You must be signed in to change notification settings - Fork 4
Debug logger #213
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 logger #213
Conversation
@@ -82,8 +82,6 @@ public function __construct( | |||
*/ | |||
public function __invoke(CliMenu $menu): void | |||
{ | |||
$menu->close(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just wondering why 👀
@@ -59,6 +59,7 @@ public function __invoke(ContainerInterface $c): CliMenu | |||
$builder->addItem( | |||
$exercise->getName(), | |||
function (CliMenu $menu) use ($exerciseRenderer, $eventDispatcher, $exercise) { | |||
$menu->close(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is it moved here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, read the pr description!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah jesus, my bad 😂 🤦
Adds a new
--debug
flag which will print all logging to the console if present.I had to refactor the menu closing, because that was currently done in the
ExerciseRenderer
which seems odd anyway, but that was causing the screen to be cleared after the exercise selected event was triggered, so anything logged then would be overwritten. I've changed it to close the menu as soon as we are in the callback for selecting an exercise.