Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not always start on boot #104

Open
coffebar opened this issue Oct 2, 2023 · 9 comments
Open

Not always start on boot #104

coffebar opened this issue Oct 2, 2023 · 9 comments

Comments

@coffebar
Copy link

coffebar commented Oct 2, 2023

This kinda workflow is "working" for me from one to another system update for like last month or two. And it is very annoying.
Need help to localize this bug or work around it. Please advise where to start.

How I reboot my computer:

  1. systemctl reboot
  2. shutdown correctly
  3. boot into Hyprland ( config )
    This script starts from exec-once:
#!/bin/bash
sleep 1
killall -e xdg-desktop-portal-hyprland
killall -e xdg-desktop-portal-wlr
killall xdg-desktop-portal
/usr/lib/xdg-desktop-portal-hyprland &
sleep 2
/usr/lib/xdg-desktop-portal &

Desktop portal is not started (gtk apps long load, firefox crashes, volume indicator missing)

  1. exit hyprland - computer hung, black screen, cooler is working hard
  2. wait for 10 minutes, and do a hard shutdown by holding the Power key.
  3. boot into Hyprland and everything works, desktop portal is working.

Sometimes it takes 2-3 reboots.

@coffebar
Copy link
Author

coffebar commented Oct 2, 2023

It was 10 minutes earlier, then I rebooted several times in a row and it does not reproduce now.
Please don't close, the problem is relevant anyways

@thejch
Copy link

thejch commented Oct 3, 2023

Have you tried logging the output
/usr/lib/xdg-desktop-portal-hyprland &> logfile

@Fuchskaute
Copy link

Fuchskaute commented Oct 4, 2023

That scripts looks like it was taken straight from the Gentoo Wiki. Using a script like that to start xdph/other desktop-portals isn't always necessary on systemd to my knowledge, they should automatically be started as part of your dbus user session. Are you starting Hyprland with dbus-run-session too? In which case you do not need that either.

I do not have any such scripts in my hyprland config and systemctl --user status xdg-desktop-portal (or any specific portal) gives me a positive output and it works just fine.

I'm curious if removing that exec-once script and properly launching Hyprland will resolve your issues.

@coffebar
Copy link
Author

coffebar commented Oct 4, 2023

@Fuchskaute
The script was taken straight from hyprland wiki
Tested without it and it did not work. The script is required for me, or need to do some more configuration.

I believe the described problem is related to the timing of this script. Sleep 1-2 seems not reliable values.

pacman -Q | awk '{print $1}' | grep '^xdg-'

xdg-dbus-proxy
xdg-desktop-portal
xdg-desktop-portal-hyprland-git
xdg-user-dirs
xdg-utils

is it the correct set of programs?

@thejch Unfortunately, logging gives nothing - empty log
Only this thing spamming from xdg-desktop-portal every time
(/usr/lib/xdg-desktop-portal:3025): xdg-desktop-portal-WARNING **: 11:08:56.042: No skeleton to export

@Fuchskaute
Copy link

I apologize in that case, that seems rather interesting..

@kaii-lb
Copy link

kaii-lb commented Oct 6, 2023

same issue here, and now flatpak apps all report
(com.github.tchx84.Flatseal:2): Gdk-WARNING **: 18:07:55.873: Failed to read portal settings: GDBus.Error:org.freedesktop.DBus.Error.UnknownMethod: No such interface “org.freedesktop.portal.Settings” on object at path /org/freedesktop/portal/desktop

which is annoying as hell (i use left aligned window controls)

@NgoHuy
Copy link
Contributor

NgoHuy commented Oct 12, 2023

I have same issue, but no working, it related to #114 , xdgh crashed
image

@jones-sam
Copy link

I know this isn't a "real" solution, but I fixed this issue (at least for now) just by switching from xdg-desktop-portal-hyprland-git to xdg-desktop-portal-hyprland

@coffebar
Copy link
Author

coffebar commented Dec 9, 2023

I know this isn't a "real" solution, but I fixed this issue (at least for now) just by switching from xdg-desktop-portal-hyprland-git to xdg-desktop-portal-hyprland

You know, it will work till next update of the xdg-desktop-portal-hyprland

EpicPlayzGames added a commit to EpicPlayzGames/Dotfiles that referenced this issue Mar 5, 2024
Update to remove xdg-desktop-portal script from exec-once as it would crash xdg-desktop-portal on boot when systemd tried to start the instance. Script is not required to get xdg-desktop-portal and xdg-desktop-portal-hyprland working

Related Issue causing fix hyprwm/xdg-desktop-portal-hyprland#104 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants