Bug 495021

Summary: Plasmashell fails when plasmoid files are symlinked
Product: [Plasma] plasmashell Reporter: Soup <bmanbros>
Component: Brightness and Color widgetAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED DOWNSTREAM    
Severity: normal CC: natalie_clarius, nate
Priority: NOR    
Version First Reported In: 6.2.1   
Target Milestone: 1.0   
Platform: NixOS   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: The specific errors output by running "plasmawindowed org.kde.plasma.brightness"

Description Soup 2024-10-19 03:15:02 UTC
Created attachment 175009 [details]
The specific errors output by running "plasmawindowed org.kde.plasma.brightness"

SUMMARY

On NixOS, if you choose to use an overlay to rebuild something like say, powerdevil, to re-enable ddcutil support, the plasmoids it provides break because the overlay symlinks the individual files, which plasmashell errors out on, same goes with the plasmawindowed debugger.

STEPS TO REPRODUCE
1. Build any plasma component that provides plasmoids with a NixOS overlay.
2. Restart any relevant services, such as plasmashell.
3. Attempt to open a plasmoid provided by the component.

OBSERVED RESULT

The plasmoid is replaced with an error message that it "does not exist".

EXPECTED RESULT

The plasmoid loads as expected.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: NixOS unstable 24.11
KDE Plasma Version: 6.2.1
KDE Frameworks Version: 6.7.0
Qt Version: 6.8.0

ADDITIONAL INFORMATION
The override in question, which is added to the configuration.nix's import list:

let
  powerdevil-overlay = final: prev: {
    kdePackages = prev.kdePackages // {
      powerdevil = prev.kdePackages.powerdevil.overrideAttrs
        (old: { buildInputs = old.buildInputs ++ [ final.ddcutil ]; });
    };
  };
  in {
    hardware.i2c.enable = true;
    nixpkgs.overlays = [ powerdevil-overlay ];
}
Comment 1 Nate Graham 2024-11-06 21:53:38 UTC
This looks like a distro-specific tooling or packaging issue. I'd suggest talking to the NixOS folks about it.