Model the stepping expected by OnlinePythonTutor by only printing states if the next state's line is different, or the next state is the end of the trace.