Added utilities

Added some utilities for debugging stuff in the console when stuff goes
wrong. Pretty useful.