gnome-terminator / terminator

multiple GNOME terminals in one window
https://gnome-terminator.org
GNU General Public License v2.0
2.15k stars 259 forks source link

Terminator not spawning a child #768

Open AlienusV opened 1 year ago

AlienusV commented 1 year ago

Before opening an issue, please try starting terminator with an empty config file, by issuing terminator -u -g /dev/null and see if it starts normally.

If it does, and you still want to open the bug, then please attach the config file, usually found at $HOME/.config/terminator/config to the issue

terminator.txt Terminator version 2.1.3

Fill out as many of these fields as you can

Describe the bug A clear and concise description of what the bug is. While using the "Arch Linux Updates Indicator" extension in Gnome, I click the "Update Now" button on the extension which runs /usr/bin/terminator -x "yay -Syu; echo Done; read _" in the background, the Terminator window does not appear. When I open it through the shortcut, it does.

To Reproduce Steps to reproduce the behavior: I can't reproduce the behavior every time, it just happens randomly. I just notice that there are updates and click the "Update Now" button, and randomly it does not open.

Expected behavior A clear and concise description of what you expected to happen. To open a window with the given command.

Error Codes If applicable, add error codes to help explain your problem.

May 28 14:11:23 archlienus systemd[1849]: Started Application launched by gnome-shell.
May 28 14:11:23 archlienus gnome-shell[771462]: Traceback (most recent call last):
May 28 14:11:23 archlienus gnome-shell[771462]:   File "/usr/bin/terminator", line 126, in <module>
May 28 14:11:23 archlienus gnome-shell[771462]:     TERMINATOR.layout_done()
May 28 14:11:23 archlienus gnome-shell[771462]:   File "/usr/lib/python3.11/site-packages/terminatorlib/terminator.py", line 326, in layout_done
May 28 14:11:23 archlienus gnome-shell[771462]:     terminal.spawn_child()
May 28 14:11:23 archlienus gnome-shell[771462]:   File "/usr/lib/python3.11/site-packages/terminatorlib/terminal.py", line 1562, in spawn_child
May 28 14:11:23 archlienus gnome-shell[771462]:     self.vte.feed(_('Unable to find a shell'))
May 28 14:11:23 archlienus gnome-shell[771462]: TypeError: Item 0: Must be number, not str
May 28 14:11:27 archlienus systemd[1849]: Started Application launched by gnome-shell.
May 28 14:11:27 archlienus gnome-shell[771498]: Traceback (most recent call last):
May 28 14:11:27 archlienus gnome-shell[771498]:   File "/usr/bin/terminator", line 126, in <module>
May 28 14:11:27 archlienus gnome-shell[771498]:     TERMINATOR.layout_done()
May 28 14:11:27 archlienus gnome-shell[771498]:   File "/usr/lib/python3.11/site-packages/terminatorlib/terminator.py", line 326, in layout_done
May 28 14:11:27 archlienus gnome-shell[771498]:     terminal.spawn_child()
May 28 14:11:27 archlienus gnome-shell[771498]:   File "/usr/lib/python3.11/site-packages/terminatorlib/terminal.py", line 1562, in spawn_child
May 28 14:11:27 archlienus gnome-shell[771498]:     self.vte.feed(_('Unable to find a shell'))
May 28 14:11:27 archlienus gnome-shell[771498]: TypeError: Item 0: Must be number, not str

Desktop (please complete the following information):

Additional context Add any other context about the problem here. The issue report on Arch-Update repo.

mattrose commented 1 year ago

That seems like Terminator can't find a valid shell to run that command. What shell are you running, and what shells do you have installed?

AlienusV commented 1 year ago

I use bash, and didn't install anything else manually. I found that there is a file that list installed shells, /etc/shells, contents of that file is

#Pathnames of valid login shells.
# See shells(5) for details.

/bin/sh
/bin/bash
/usr/bin/git-shell
/bin/rbash
/usr/bin/rbash
vssdeo commented 1 year ago

I had looked at the -x behavior and documented in Ref: https://github.com/gnome-terminator/terminator/issues/829

Also: a patch was provided Ref: https://github.com/vssdeo/terminator/commit/862554c24d10ead377782cef1458c27b428a34c9 but the change needs to be cross-checked with expected and current behavior. I didn't put up a pull request as I first wanted this change to get verified.