debug and update