Skip to content

Commit

Permalink
Merge pull request #57 from doronz88/refactor/continue-stop-logs
Browse files Browse the repository at this point in the history
hilda_client: only log continue/stop messages via key bindings
  • Loading branch information
doronz88 authored May 28, 2024
2 parents 5050b8d + a909fae commit 23358f8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 0 additions & 4 deletions hilda/hilda_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -340,8 +340,6 @@ def stop(self, *args) -> None:

if not self.process.Stop().Success():
self.log_critical('failed to stop process')
else:
self.log_info('Process Stopped')

def cont(self, *args) -> None:
""" Continue process. """
Expand All @@ -357,8 +355,6 @@ def cont(self, *args) -> None:

if not self.process.Continue().Success():
self.log_critical('failed to continue process')
else:
self.log_info('Process Continued')

def detach(self):
"""
Expand Down
4 changes: 2 additions & 2 deletions hilda/ipython_extensions/keybindings.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ def register_keybindings():
hilda = ipython.user_ns['p']
keys_mapping = {Keys.F7: hilda.step_into,
Keys.F8: hilda.step_over,
Keys.F9: hilda.cont,
Keys.F10: hilda.stop}
Keys.F9: lambda _: (hilda.log_info('Sending continue'), hilda.cont()),
Keys.F10: lambda _: (hilda.log_info('Sending stop'), hilda.stop())}

insert_mode = ViInsertMode() | EmacsInsertMode()
registry = ipython.pt_app.key_bindings
Expand Down

0 comments on commit 23358f8

Please sign in to comment.