mode code style
added top-level exception handler for NoClassDefFoundError, etc