Added unexpected state errors to log