is there any recommended way of looking into why some code is giving an "Maximum call stack size exceeded" error?