Simplified exception handling for debugging