Skip to content

Instantly share code, notes, and snippets.

Last active March 19, 2020 16:20
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
What would you like to do?
Enable logging in RTT
# Add to beginning of cgi:
import logging
import pprint
import config
pp = pprint.PrettyPrinter(indent=4)
logging.basicConfig(filename=config.ROOT_PATH+"/rtt.log", level=logging.DEBUG)
# Add debugging print statements like this
logging.debug("reordering following sequence at depth " + str(depth))
# Run these commands to initialize logfile:
touch rtt.log
chmod 777 rtt.log
# Then to see and follow the log while you test:
tail -f -n 100 rtt.log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment