Running Ion from pwsh behaves weird on exit
First off, for those who don’t know … pwsh refers to PowerShell Core, the open-source, cross-platform version of PowerShell. I use it as my default shell.
- When running Ion inside pwsh inside bash, program exit stops the pwsh job in bash.
- When running Ion inside pwsh running directly in a terminal emulator, program exit causes pwsh to crash.
- Exiting Ion from inside pwsh inside pwsh causes both pwsh instances to crash or be suspended respectively.
These things happen regardless of what Ion does, be it displaying help or version, running commands directly, or an interactive session.
This does not happen when running Ion as a direct command (like
pwsh -c ion), nor when running it from piped input (like
echo ion | pwsh); only when running it from an interactive session and typing the command directly.
This happens both in gnome-terminal and the Linux console.
Ion is the only program I have ever had this issue with.
Since this is a very niche issue, I’d be willing to look into this myself.
Log for the first variant:
andreas@ak-ubuntu:~/programming/rust/ion$ pwsh PowerShell 6.1.2 Copyright (c) Microsoft Corporation. All rights reserved. https://aka.ms/pscore6-docs Type 'help' to get help. PS /home/andreas/programming/rust/ion> ./target/release/ion -c "echo test" test + Stopped pwsh andreas@ak-ubuntu:~/programming/rust/ion$ jobs + Stopped pwsh andreas@ak-ubuntu:~/programming/rust/ion$ fg pwsh PS /home/andreas/programming/rust/ion> exit andreas@ak-ubuntu:~/programming/rust/ion$
Apport tells me pwsh SIGABRT-ed itself after displaying that exception stack trace.
- Operating system: Ubuntu 18.10 x86_64
- Ion: ion 1.0.0-alpha, rev 56ea83ef
- toolchain: stable-x86_64-unknown-linux-gnu
- rustc: 1.32.0 (9fda7c223 2019-01-16)