stop-hooks were not intended to be interactive, that would be really confusing when there are many in flight. So this patch marks the results as non-interactive.
Beyond correctness, then main reason for doing this patch is that when you go to run a command based stop hook that includes a Python command, if the command is marked as interactive, Python would try to act on stdin (fflush it) when switching to the Python Session, and if stdin was backed by an lldb NativeFile, the the fflush would deadlock against the I/O handler thread that was sitting in read on the same file handle.
That is a more general problem that this patch does not address. The only place it has shown up IRL is in this scenario, and since doing the right thing for the stop-hook execution works around it, the more general fix can wait on somebody else's free time. But I did add a test that will deadlock without this patch, and succeeds with it.