RaphaelRochet / arch-update

Update indicator for ArchLinux and Gnome-Shell
https://extensions.gnome.org/extension/1010/archlinux-updates-indicator/
GNU General Public License v3.0
232 stars 69 forks source link

Update button not working after a while #207

Closed AlienusV closed 1 year ago

AlienusV commented 1 year ago

Arch Linux 6.3.3-arch1-1 Gnome 44.1 Arch-Update v53(it seems 53, but the latest version seems to be 52, so I'm not sure about that)

Command to update packages: terminator -x "yay -Syu; echo Done; read _"

After using it for a while, clicking the "Update now" button does nothing. It works for a couple of days, I always update by clicking that update button, but sometimes it doesn't even open the terminator, just gets clicked on and then nothing.

Editing the command making it purposefully not work and reverting these changes can fix it, but it got annoying after it happening more than 10 times.

About section

RaphaelRochet commented 1 year ago

Hi, When it has stopped working, can you run journalctl -f in a terminal to see logs and try again. Maybe something useful can be logged there.

AlienusV commented 1 year ago

I'll let you know when and if it happens again. It might take a week or two.

AlienusV commented 1 year ago

It happened again but this time after clicking 2 or 3 times it opened terminator.

journal -f output when it did not open:

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

journal -f when it opened:

May 28 14:16:04 archlienus systemd[1849]: Started Application launched by gnome-shell.
May 28 14:16:04 archlienus dbus-daemon[575]: [system] Activating via systemd: service name='org.freedesktop.home1' unit='dbus-org.freedesktop.home1.service' requested by ':1.4114' (uid=0 pid=772588 comm="sudo pacman -S -y --config /etc/pacman.conf --")
May 28 14:16:04 archlienus dbus-daemon[575]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.home1.service': Unit dbus-org.freedesktop.home1.service not found.
May 28 14:16:04 archlienus systemd[1849]: Started VTE child process 772580 launched by terminator process 771528.
May 28 14:16:04 archlienus sudo[772588]: pam_systemd_home(sudo:auth): systemd-homed is not available: Unit dbus-org.freedesktop.home1.service not found.

So it seems like this instance was terminator related. But the fact that it opened after clicking 2–3 times, feels like it was a fluke with the terminator app.

After searching journalctl whether this issue happened before, I've found out this exact issue happened 7 times (on 7 different days, in total 16 times) in the past. Search command: journalctl --since "1 year ago" -u user@1000.service | grep -i "terminator.lay" (this laptop is not older than 1 year)

Checking these 7 instances, revealed they were errors only about terminator. Only on the last instance there was an error about arch-update:

May 25 23:24:14 archlienus gnome-shell[1953]: JS ERROR: Gio.DBusError: GDBus.Error:org.freedesktop.DBus.Error.Failed: error occurred in AboutToShow
                                              _promisify/proto[asyncFunc]/</<@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:453:45
                                              ### Promise created here: ###
                                              sendAboutToShow@/home/alienus/.local/share/gnome-shell/extensions/appindicatorsupport@rgcjonas.gmail.com/dbusMenu.js:501:48
                                              sendAboutToShow@/home/alienus/.local/share/gnome-shell/extensions/appindicatorsupport@rgcjonas.gmail.com/dbusMenu.js:197:22
                                              _onMenuOpened@/home/alienus/.local/share/gnome-shell/extensions/appindicatorsupport@rgcjonas.gmail.com/dbusMenu.js:935:28
                                              _callHandlers@resource:///org/gnome/gjs/modules/core/_signals.js:130:42
                                              _emit@resource:///org/gnome/gjs/modules/core/_signals.js:119:10
                                              open@resource:///org/gnome/shell/ui/popupMenu.js:932:14
                                              toggle@resource:///org/gnome/shell/ui/popupMenu.js:805:18
                                              vfunc_button_press_event@/home/alienus/.local/share/gnome-shell/extensions/appindicatorsupport@rgcjonas.gmail.com/indicatorStatusIcon.js:414:23
---
May 25 23:24:27 archlienus gnome-shell[1953]: Unhandled promise rejection. To suppress this warning, add an error handler to your promise chain with .catch() or a try-catch block around your await expression. Stack trace of the failed promise:
                                                _promisify/proto[asyncFunc]@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:448:16
                                                openExtensionPrefs@resource:///org/gnome/shell/ui/extensionSystem.js:254:26
                                                openPrefs@resource:///org/gnome/shell/misc/extensionUtils.js:255:26
                                                _openSettings@/home/alienus/.local/share/gnome-shell/extensions/arch-update@RaphaelRochet/extension.js:207:18
                                                activate@resource:///org/gnome/shell/ui/popupMenu.js:202:14
                                                vfunc_button_release_event@resource:///org/gnome/shell/ui/popupMenu.js:146:14
RaphaelRochet commented 1 year ago

Well ... It looks like the warning about Arch-Update is triggered by the error from "appindicatorsupport". Moreover, the stack trace show that it occured in GNOME code, not mine.

As much as I am willing to help, I'm afraid I can't do anything there.

Maybe report an issue on Terminator ?