If the external command gets in the "Terminate batch job (Y/N)?" state, this causes issue with rustyline.
We should try to avoid ever getting into this situation. There are some possible workarounds that could be explored:
https://superuser.com/questions/35698/how-to-supress-terminate-batch-job-y-n-confirmation/35741#35741
https://superuser.com/questions/35698/how-to-supress-terminate-batch-job-y-n-confirmation/498798#498798