Skip to content

Conversation

maxandersen
Copy link
Contributor

its notoriously hard to get kernel output so added ipython inspired %log commands magic
to enable better inspection.

with this the kernel can start adding logging more widespread for easier debugging.

Usage: %log <command>

Commands:
  start [filename] - Start logging to file (default: <kernelname>.log)
  stop             - Stop logging and close log file
  on               - Resume logging (if paused)
  off              - Pause logging (but keep file open)
  state            - Show current logging status
  level <LEVEL>    - Set logging level (SEVERE, WARNING, INFO, CONFIG, FINE, FINER, FINEST)

Examples:
  %log start                   - Start logging to <kernelname>.log
  %log start myapp.log         - Start logging to myapp.log
  %log off                     - Pause logging
  %log on                      - Resume logging
  %log state                   - Check status
  %log level WARNING           - Set logging level
  %log stop                    - Stop and close log file

@maxandersen
Copy link
Contributor Author

any feedback/comments?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant