Bug 505528

Summary: Background: Double-click triggers: Custom Command: empty string passed for "{path}" when triggered in remote folder
Product: [Applications] dolphin Reporter: Sam Birch <bugs.kde.org>
Component: generalAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: REPORTED ---    
Severity: minor CC: dolphin-bugs-null
Priority: NOR    
Version First Reported In: 25.04.1   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Sam Birch 2025-06-12 15:25:16 UTC
SUMMARY


STEPS TO REPRODUCE
1. Create executable file ~/bin/bg-dbl-clk-test with contents:
----8<-cut-here-----------------------------------------------------------------
#!/usr/bin/env bash

printf "[%s] first arg is: “%s”\n" "$(date)" "$1" > ~/bg-dbk-clk-test.out
----8<-cut-here-----------------------------------------------------------------
2. In Dolphin, set Background: Double-click triggers: to "Custom Command".
3. Set the custom command to: $HOME/bg-dbl-clk-test {path}
4. Open a remote folder in Dolphin and double-click the background. I used: fish://sam-birch@buildvm:22/home/sam-birch/projects/linux/arch/arm64/boot/dts/rockchip/
5. Look at the contents of ~/bg-dbk-clk-test.out

OBSERVED RESULT
[Thu Jun 12 11:17:02 AM EDT 2025] first arg is: “”

EXPECTED RESULT
[Thu Jun 12 11:17:02 AM EDT 2025] first arg is: “/run/user/1000/kio-fuse-gPPzTW/fish/sam-birch@buildvm:22/home/sam-birch/projects/linux/arch/arm64/boot/dts/rockchip”

SOFTWARE/OS VERSIONS
Operating System: Fedora Linux 42
KDE Plasma Version: 6.3.5
KDE Frameworks Version: 6.14.0
Qt Version: 6.9.0
Kernel Version: 6.14.9-300.fc42.x86_64 (64-bit)
Graphics Platform: Wayland
Processors: 20 × 12th Gen Intel® Core™ i7-12700H
Memory: 31.0 GiB of RAM
Graphics Processor 1: Intel® Iris® Xe Graphics
Graphics Processor 2: NVIDIA GeForce RTX 3050 Laptop GPU
Manufacturer: LENOVO
Product Name: 21DA000WUS
System Version: ThinkPad T15p Gen 3

ADDITIONAL INFORMATION
It'd be cool to get the translated kio-fuse path, but I'd also be happy with the raw KIO URL — I can always make a wrapper script that does the kio-fuse mount and looks up the path. Here's my little script that does that, in case it's of interest:
----8<-cut-here-----------------------------------------------------------------
#!/usr/bin/env fish

function main -a url
    dbus-send --print-reply=literal --type=method_call --dest=org.kde.KIOFuse \
        /org/kde/KIOFuse org.kde.KIOFuse.VFS.mountUrl string:$url \
    | string trim -l
    printf "\n"
end

main $argv
----8<-cut-here-----------------------------------------------------------------