debugger had some bugs