Closed Glint-Eye closed 1 year ago
Same here, as of this morning (Oct. 4, 2023).
albert did not start anymore.
Uninstalling and reinstalling helped insofar that it now starts again, but the same warning appears:
there are two logfiles in .cache/albert. the current and the past log. please post the past log. the one of the crashed process if you just received this messagebox.
okay so albert.last.log says the following:
12:25:34 WARN Albert has not been terminated properly. Please check your crash reports and report an issue.
12:25:37 INFO There is another instance of albert running.
albert.log says:
12:28:56 WARN Albert has not been terminated properly. Please check your crash reports and report an issue.
12:29:04 INFO Hotkey set to Ctrl+Space
12:29:05 INFO Indexing ****
12:29:05 INFO Python version: 3.10.12 (main, Jun 11 2023, 05:26:28) [GCC 11.4.0]
Btw, I get the same popup message when I start albert while an instance is already running.
I have the same problem, ~/.cache/albert/running
just doesn't get deleted on shutdown/reboot.
~/.cache/albert/albert.last.log
and ~/.cache/albert/albert.log
are always empty.
shutdown/reboot
does this issue occur only on reboot? Which desktop environment?
KDE. I tested it again a few times and this time there was no problem, maybe it was on my end.
Currently, I only see this warning if I try to run Albert from Albert.
Pop OS 22.04. For me it happens on reboot and shutdown. Only when I end the "albert" process manually before shutdown/reboot it doesn't occur.
I can corroborate that this is also happening for me in Gnome 44 on Fedora 38. Manual exit of Albert removes the file but a full machine shutdown does not.
New day, new startup.
I can report that I actually got 2 of these windows (I already OK-ed the 1st one):
Looks like this issue appears only on reboot. I assume that either session management is not handled correctly or the DE does not implement it correctly. Can you please add QT_LOGGING_RULES="*.debug=true"
to the exec line in the desktop entry at /usr/share/applications/albert.desktop, such that it look like this:
#!/usr/bin/env xdg-open
[Desktop Entry]
Categories=Utility;
Comment=A desktop agnostic launcher
Exec=/usr/bin/env QT_LOGGING_RULES="*.debug=true" QT_QPA_PLATFORM=xcb albert
GenericName=Launcher
Icon=albert
Name=Albert
StartupNotify=false
Type=Application
Version=1.0
Then do two restarts (one to actually get this desktop file started using the autostart mechanism and the second to get this instance terminated by a restart) and then post the albert.last.log in a pastebin?
Edited the albert.desktop
-file to this:
So, as requested albert.last.log
(which is quite minimal :/) after 2 restarts:
Here's also albert.log:
Same issue here. I am using KDE neon 5.27 Release 22.04.
I do add the QT_LOGGING_RULES="*.debug=true"
. And after 2 restarts, and the 2 logs look as follows:
And similar text repeated a lot of times for the log:
I uploaded the full log in my forked repo, link here: full log.
Looks like this issue appears only on reboot.
FYI: I experience the same when logging out and back in.
I think i found the problem. Session managers on some systems restore the session including albert. But also you probably have albert set to autostart on login. Thus albert is run twice. Can you confirm?
Well the obvious thing is not to report a crash if the app is running atm…
Albert is set to autostart, yes. I don't remember setting it up like that, so I assume it is done on installation? FYI: I'm using Gnome 44 on Ubuntu 23.04.
@bashopman iirc no. there is a checkbox in the settings for it. maybe you checked it once.
@ManuelSchneid3r that is likely, yes. I tend to check settings menu's and that sounds like a convenient option. ;) The "autostart" checkbox was set. Unchecked it now.
@bashopman this should not be necessary. ill try to move the crash indicator into the rpc server. i am not sure though how particular systems handle leftover local sockets on reboot. hopefully they remain such that crashes can be recognized.
in 0.22.14. let me know how it works out.
Hi @ManuelSchneid3r Executed the following steps to test:
Not sure what I can do more...
5. ALT-Space (my hotkey combination) didn't work though.
do you use the internal hotkey or some sort of external hotkey firing albert show or toggle?
gave it a testrun on Kubuntu 20.04. everything is fine there. what are the others experiencing? @henrikgit @tomporter518 @stasadev @Glint-Eye @DirkFi
@ManuelSchneid3r I'm using the hotkey defined from the Albert settings. Note that I'm using Gnome 44 and not KDE. And, not sure if relevant, I'm using X.org. When using Wayland, I don't get Albert to work at all.
KDE 5.27.8 Albert v0.22.14
All good when I reboot via KDE menu > restart.
But I see a warning every time if I reboot with /usr/bin/reboot
(for me it's a part of systemd-sysvcompat).
This reminds me of an issue which is years old (#197). reboot
does not reboot session friendly. It SIGTERMs all processes, notably the XServer as well, which causes QT programs to fail with ICE errors (whatever this is). Also posted a qt bug on this.
I think i found the problem. Session managers on some systems restore the session including albert. But also you probably have albert set to autostart on login. Thus albert is run twice. Can you confirm?
Well the obvious thing is not to report a crash if the app is running atm…
Just installed 0.22.14. did 1 shutdown, then 2 reboots. Everytime still got the message. Tried then to deactivate autostart in albert options. Process is not being restored after reboot. Had to start albert manually again. And then, after starting manually without any prior instance running i got the message aswell.
I think i found the problem. Session managers on some systems restore the session including albert. But also you probably have albert set to autostart on login. Thus albert is run twice. Can you confirm?
Well the obvious thing is not to report a crash if the app is running atm…
@ManuelSchneid3r In my case for Albert 0.22.14, you are right! I deactivated the autostart in albert. After I do a restart, albert started automatically without any errors! I tested several times and it all behaved as expected! Seems like my case is different from Glint-Eye.
@ManuelSchneid3r
TLDR: No warning anymore upon startup (after login, that is). For that, I did the following on my Arch machine:
But what do you know.... going into XFCE's settings again, I found that Albert was added again:
Hm.
After a new reboot, I again have the 2 popup windows and a new one (lower right in screenshot):
- Removed the autostart entry for albert in XFCE's settings
- Left the check mark in albert's settings for startup.
They both do the same. The mechanism is standardized. If you put a check albert autostart in the settings the entry will also appear in your xfce stettings.
For the hotkey fail please post the terminal output. Meaning make sure albert is not running, and start it from terminal using albert -d
.
@Glint-Eye please post albert -d -r
albert -d
, output is:@henrikgit looks like this output is incomplete
Thought the output would be enough, but here is everything:
Another new try with no entry for autostarting albert in XFCE's settings and with an unchecked box in albert's settings for startup (don't know when exactly XFCE's settings get checked so that the box in albert's settings get set automatically or vice versa).
... so per the settings in the desktop environment and albert, it should not have been started... right?
Regardless, after a new boot 3 minutes ago, I got one (1) window with "Albert has not been terminated properly".
so per the settings in the desktop environment and albert, it should not have been started... right?
It depends. XFCE probably restores your session. Meaning all apps running on shutdown/logout will be opened again on login.
20:36:27 [info:albert] Hotkey set to Ctrl+Space
Looks like hotkey is working, right? This issue is out of scope here. Please open a new issue for anything else but the not-terminated-properly issue.
I totally lost the overview here. Obv the recent fix worked for some of us. 0.22.14 does not print this error anymore if multiple instances of albert are started. Thus the session restore and autostart problem should be fixed. Is anybody still having problems?
@stasadev KDE. Works.
@DirkFi's setup works.
@tomporter518 Gnome44/Fedora38. Does 0.22.14 solve this for you?
@Glint-Eye PopOS/22.04/pop:GNOME. Fail, even with 0.22.14.
@henrikgit: arch/XFCE. Fail, even with 0.22.14.
@henrikgit @tomporter518 @Glint-Eye Do you reboot using the session manager?
I reboot and power off with the systemd commands, meaning:
systemctl reboot
andsystemctl poweroff
@henrikgit does it work for you if you restart using the xfce session facilities?
Well. This is interesting.
@ManuelSchneid3r Yes it worked. By which I mean, Albert was restored (as you suspected here) without an error window after I rebooted. I did it via the menu:
Now I just need to find out how to execute that very command from the terminal...
@Glint-Eye please post
albert -d -r
12:42:28 [debg:albert] Albert version: 0.22.14 12:42:28 [debg:albert] Build date: Oct 6 2023 10:37:37 12:42:28 [debg:albert] Qt version: 6.2.4 12:42:28 [debg:albert] Build ABI: x86_64-little_endian-lp64 12:42:28 [debg:albert] Arch (build/current): x86_64/x86_64 12:42:28 [debg:albert] Kernel (type/version): linux/6.5.4-76060504-generic 12:42:28 [debg:albert] OS: Pop!_OS 22.04 LTS 12:42:28 [debg:albert] OS (type/version): pop/22.04 12:42:28 [debg:albert] Platform name: xcb 12:42:28 [debg:albert] Binary location: /usr/bin/albert 12:42:28 [debg:albert] Current dir: 12:42:28 [debg:albert] Font: Fira Sans Semi-Light,11,-1,5,400,0,0,0,0,0,0,0,0,0,0,1 12:42:28 [debg:albert] Language: English 12:42:28 [debg:albert] Locale: en_US 12:42:28 [debg:albert] $LANG: en_US.UTF-8 12:42:28 [debg:albert] $QT_QPA_PLATFORMTHEME: 12:42:28 [debg:albert] $PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin 12:42:28 [debg:albert] $PWD: 12:42:28 [debg:albert] $SHELL: /bin/bash 12:42:28 [debg:albert] $XDG_SESSION_TYPE: x11 12:42:28 [debg:albert] $XDG_CURRENT_DESKTOP: pop:GNOME 12:42:28 [debg:albert] $DESKTOP_SESSION: pop 12:42:28 [debg:albert] $XDG_SESSION_DESKTOP: pop 12:42:28 [debg:albert] Icon theme: Pop
For me albert hasn't been restored yet in any configuration when I disable autostart. I also use system.d commands for power off, reboot etc. But i've also tried with the regular session controls for gnome. With 0.22.14 I don't get the message anymore when I try to run another instance of albert, while albert is already running. But I still get the message after startup. Even if I autostart is deactivated and I start albert manually. It feels to me that there's something going on with process end handling on shutdown or reboot. As when I end albert process manually before shutdown / reboot I get no message on next boot.
@Glint-Eye iirc from #197 system shutdown bypasses session management entirely. Use the session tools to end your sessions.
@Glint-Eye iirc from #197 system shutdown bypasses session management entirely. Use the session tools to end your sessions.
i did that. thats what i mean by "session controls for gnome". the regular way to shutdown gnome session in pop os. like by mouse in the top panel where i can select power options like: "power off, restart, suspend". At least i don't know about any other out of the box way to end a session.
I've discovered the following: If I delete the file "ipc_socket" in "~/.cache/albert" before I launch albert after a startup i do not get the message anymore.
Sure that's exactly the file which "causes" this issue. But it's intentional. If Albert gets terminated properly the local server socket gets closed and the file (socket) deleted. In the absence of this file Albert does not give this error.
A proper shutdown has to terminate all running apps before killing the Xserver. Somewhere in between also the window-, session- and loginmanager. If it does not it is probably a bug of your desktop environment.
Alright. I guess I'll just write a script then that deletes that file before launching albert each startup. Good enough for me for now.
Thx for the input and help!
@Glint-Eye i understand that this may be frustrating, but the only proper solution is to terminate a session correctly. Killing the Xserver under the feet of a GUI application is problematic for every app. This problem affects every Qt app not only albert. Besides the annoying notification this also results in further issues (e.g. https://github.com/albertlauncher/plugins/issues/122).
Note that this is a general notification that something went wrong in the former run. To find out what happened see the logs. Use
journalctl -t albert.desktop
if the crash happened while using an instance that has been autostarted by your session manager otherwise run it in terminal and see stdout. Usealbert -d
to find issues orQ_LOGGING_RULES='*=true' albert
to include Qt internal details.Original post: