This usually happens when the script uses some commands to change terminal settings and fails to reset them back to their default before it ends.
For instance, you can simulate a situation such as this with this command:
(I expect it will look like what you're experimenting.)
You can typically get back to "normal" with the
reset command, so try pressing Ctrl+C or Return to make sure you're at the start of a new prompt, then type "reset" (you won't see anything) and Return and things might get back to normal:
It's hard to tell what
checkpoint_ps.py is doing that's leaving the terminal in a weird state... Though disabling terminal "echo" might be that... It's a common thing to do while asking for a password (so the password doesn't show up.) It looks from the output like "sudo" is getting involved, so I wouldn't expect
checkpoint_ps.py would be messing with the terminal itself... But who knows, it's possible. If you find something in there that might be related to that, maybe ask a separate question about it so we can help you figure that out too.