update the code that collect the errors of each query step, fix the issue that the error be missing