debug for exception