hyprwm / xdg-desktop-portal-hyprland

xdg-desktop-portal backend for Hyprland
BSD 3-Clause "New" or "Revised" License
273 stars 47 forks source link

fix(xdg-desktop-portal-hyprland.service.in): loosen contraints #79

Closed Mikilio closed 1 year ago

Mikilio commented 1 year ago

I removed the After constraint because of the following reasons:

  1. It serves no purpose: There is absolutely no reason why it should run after graphical-session.target as the only dependencies I was aware of seemed to be the hyprland activation and dbus.service. The former is already ensured by the conditional and the latter by the type.
  2. It creates races with applications started by xdg-desktop-autostart.target that depend on functionality provided by the xdg-desktop-portal. Many services cannot activate without xdg-desktop-portal-hyprland.service but are not supposed to be edited because they are auto-generated or conform to freedesktop standards.
  3. It can run way earlier: The necessary environment variables are initialised even before systemd start the dependencies of hyprlans-session.target. Even starting as early as basic.target already ensures that all dependencies are set. In any way systemd and dbus were made so we don't have to worry about this. not specifying anything causes the service to be started by dbus when needed.
vaxerski commented 1 year ago

Sorry but no MRs are being accepted atm due to https://github.com/hyprwm/xdg-desktop-portal-hyprland/pull/78

Mikilio commented 1 year ago

I will make another after that's finished then