flatpak / xdg-desktop-portal

Desktop integration portal
https://flatpak.github.io/xdg-desktop-portal/
GNU Lesser General Public License v2.1
564 stars 189 forks source link

Portal doesn’t work (no window show up) until I restart `xdg-desktop-portal.service` #1295

Open ariasuni opened 6 months ago

ariasuni commented 6 months ago

Operating System

Arch Linux

XDG Desktop Portal version

1.18

Desktop Environment

KDE

Expected Behavior

A file chooser dialog appear when I hit Ctrl+S on Firefox and Thunderbird without any specific manipulation.

(also, using Screenshot tool in Firefox works correctly)

Current Behavior

No window shows up when I should have a file chooser dialog. The only way I’ve found to make it work is to restart xdg-desktop-portal.service. I have this problem after every reboot.

(also, using the «Copy» option in the Firefox builtin screenshot tool makes Firefox and the desktop freeze for more than 10 seconds, and only afterward is the screenshot copied to the clipboard)

logs ``` $ echo $XDG_CURRENT_DESKTOP KDE $ cat /usr/share/xdg-desktop-portal/kde-portals.conf [preferred] default=kde org.freedesktop.impl.portal.Settings=kde;gtk; $ systemctl --user status xdg-desktop-portal.service ● xdg-desktop-portal.service - Portal service Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal.service; static) Active: active (running) since Tue 2024-03-05 19:07:04 CET; 3h 42min ago Main PID: 1271 (xdg-desktop-por) Tasks: 5 (limit: 16618) Memory: 5.4M (peak: 6.2M) CPU: 228ms CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/xdg-desktop-portal.service └─1271 /usr/lib/xdg-desktop-portal mars 05 19:07:04 potipat systemd[1147]: Starting Portal service... mars 05 19:07:04 potipat xdg-desktop-por[1271]: No skeleton to export mars 05 19:07:04 potipat systemd[1147]: Started Portal service. $ systemctl --user status xdg-desktop-portal.service ● xdg-desktop-portal.service - Portal service Loaded: loaded (/usr/lib/systemd/user/xdg-desktop-portal.service; static) Active: active (running) since Tue 2024-03-05 22:55:24 CET; 3s ago Main PID: 24047 (xdg-desktop-por) Tasks: 8 (limit: 16618) Memory: 3.6M (peak: 4.6M) CPU: 96ms CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/xdg-desktop-portal.service └─24047 /usr/lib/xdg-desktop-portal mars 05 22:55:23 potipat systemd[1147]: Starting Portal service... mars 05 22:55:24 potipat systemd[1147]: Started Portal service. ```

Steps to Reproduce

  1. Install xdg-desktop-portal and xdg-desktop-portal-kde (doesn’t change anything if I have xdg-desktop-portal-gtk installed or not)
  2. Put export GTK_USE_PORTAL=1 in ~/.profile
  3. Reboot
  4. Launch Firefox
  5. Try to save a webpage

Anything else we should know?

It works perfectly fine with 1.16.

PolisanTheEasyNick commented 5 months ago

I have the same issue, but for me obs can't get a desktop and also screen/window picker for streaming won't appear until xdg-desktop-portal service not restarted Arch Linux, KDE Plasma 6, Wayland+nvidia-dkms

ariasuni commented 5 months ago

I noticed it works now, not sure if it’s due to xdg-desktop-portal 1.18.2 or xdg-desktop-portal-kde 6.0.3 or a Firefox update or something else.