Electron applications launch invisibly

cc @bogdancovaciu

Hi,

So I’ve had this issue where application when I reboot, some applications (like Riot/element and google-keep-nativefier , sometimes even discord) launch (I can see them in ksysguard) but they aren’t visible on the desktop. (they’re not on a virtual desktop either)

What I have noticed is that when this happens, usually the invisible applications are under systemd instead of under plasmashell (in ksysguard):


When I manually open Discord:

I have them set in autostart in the system settings:
Screenshot_20200807_131342
And it’s also set to only start when plasma has been started.

I should also mention that I have another problem which might be related?:
They seem to lose their settings. So with Riot/element, I have to reenter my login most of the time.
And with Discord as well, and the history of my emote usage is also gone. I’m not sure how that’s possible though

i’ve already re-installed them multiple times

I don’t know what’s going wrong. Any ideas?

Strit7 August 2020 11:37#2

Maybe they are set to “Launch automatically at boot/login”?
Do you have a tray icon with them?

Thibaultmol7 August 2020 11:38#3

Maybe they are set to “Launch automatically at boot/login”?

Well yeah, I set to autostart, via the autostart menu in the system settings. Like I said in my post

I don’t see the icon in the system tray

bogdancovaciu7 August 2020 12:31#4

Maybe you have to hit the Advanced button, once one selected, and set to Autostart only in Plasma .
With the changes of the Tray, maybe a delayed startup will help too.
For example:
Exec=sleep 10s && discord
in the discord.desktop file inside your ~/.config/autostart/

Thibaultmol7 August 2020 12:40#5

I already have it set to only start in plasma.

And don’t think that adding a sleep is going to help it appear. Keep in mind, the window itself is just also invisible. it’s not just that there is no icon in the system tray

bogdancovaciu7 August 2020 13:27#6

Ok, i will install it myself and make a test even tho i don’t use it, since it seems we have to get argumentative here.

Was the same with pamac

Edit: Made my own test on two installs. Discord starts from Autostart with no problem, and no need to change anything about the autostart. The window of the app is visible with the default Manjaro provided theme.

image


Thibaultmol
8 August 2020 20:56#7

huh… weird.

what should I change in the exec field on the .desktop file so that it logs to a file (can’t find a proper solution online).
Maybe that’ll clear something up?

Screenshot_20200808_225044

ACTUALLY:

I just noticed something. So the ‘autostart in plasma’ option wasn’t checked for Discord (even though i’m 200% it was).
So I checked it.
Rebooted.
Discord launched and was logged in (so kept it’s settings I guess).
BUT when I checked the Autostart again in the system settings now. That checkbox was UNCHECKED again.
So somehow it’s not saving that checkbox… or changes it?

bogdancovaciu9 August 2020 06:16#8

Yeah, there is something to it. I was able to reproduce the issue you described on a very old VBox VM install, but nothing concludent to shade some light of why is happening.
Try to force fix the ownership of your home directory to your user if only this is the issue at hand.

If you use autologin, sometimes the files get owned by your username and the group autologin , and that changes sometimes too, making some settings to not survive the reboot. I have no clue why does that sometimes, but i did noticed it.

Thibaultmol9 August 2020 09:58#9

Just so I don’t fck anything up. What is the exact chmod command I should run on my home directory?

bogdancovaciu9 August 2020 10:31#10

sudo chown -R $USER $HOME
should do it.

So I did that. But even after multiple reboots. I’m still having this issue.

@bogdancovaciu

Hey, welcome back!

I wonder if this issue (i read again our conversation, but is late here and my eyes do’t work as well) could be related to the theme used and/or that maybe remove the Work path from the discord.desktop file you have in autostart folder. I will have to make some tests for that, as for now is unclear why you have this issue.

So right now I have
global theme set to Arc Dark,
plasma style to arc dark
application style: fusion
login screen: Sweet
Splashscreen: Breath2

so just reset those to defaults?

And about my discord.desktop. Current it’s this:

[Desktop Entry]
Name=Discord
StartupWMClass=discord
Comment=All-in-one voice and text chat for gamers that's free, secure, and works on both your desktop and phone.
GenericName=Internet Messenger
Exec=/usr/bin/discord
Icon=discord
Type=Application
Categories=Network;InstantMessaging;
Path=/usr/bin
Path=/usr/bin

and just remove those 2 path’s (not sure why there are two actually :thinking: )

Not sure this works that good with the new KDE Plasma. Didn’t test in long time. Try breeze, just to be sure.

One should suffice.

1 Like

So. Update since I’ve changed those settings: Of the 3 times that I have rebooted today. Discord started correctly on all 3.
google-keep-nativefier only 1/3 (other 2 times it was just invisible:)
Screenshot_20200816_185828

It is interesting to see as well that if it’s properly launched, it shows the app’s icon in Ksysguard:
Screenshot_20200816_192044

EDIT: And Riot also didn’t launch

2 boots today. both didn’t launch Discord, Element or google keep correctly

Interesting development?
Youtube music lately has been starting up almost all the time correctly BUT seems to have a problem closing. Both trying to close the application from the taskbar, as clicking the close button the window and even ALT+F4 can’t close the application.

Does that help to come up with any more debugging ideas?