Fixes some bugs related to deterministic mode 1 & debugger