This forum has been archived. All content is frozen. Please use KDE Discuss instead.

In .desktop files, %u and %U do not follow Freedesktop specs

Tags: None
(comma "," separated)
Vianney Stroebel
Registered Member
Posts
4
Karma
0
OS
In the Freedesktop specifications (http://standards.freedesktop.org/deskto ... 01s06.html):


%u A single URL. Local files may either be passed as file: URLs or as file path.

%f A single file name [...] If files are not on the local file system (i.e. are on HTTP or FTP locations), the files will be copied to the local file system and %f will be expanded to point at the temporary file.


This is not how KDE 4.8.1 works for files locate on a remote kioslave: in a Dolphin service menu entry for sftp://user@host/path/to/myfile.txt, %u will contain the path to a temporary file: /var/tmp/kdecache-<username>/krun/<randomnumber>myfile.txt

This happens even though the service menu entry contains:

Code: Select all
X-KDE-Protocols=sftp

or
Code: Select all
X-KDE-Protocols=KIO


in the "[Desktop Entry]" section or in the "[Desktop Action ...]" section.

As a result, a service menu entry meant to open a file in Kate ("Exec=kate %u"), for example, will only open the temporary cached file. Kate does not save the remote file when saving the cached file (altough it asks if I want to upload the file when I close Kate).

Instead, %u should contain the sftp://... url and %f should contain the /var/tmp/kdecache-... cached file path.

Opening the file with the "Open With" context menu does work as expected (it opens the sftp://... url, which Kate handles perfectly).

The same problem occurs with the fish:// protocol (and probably any other kioslave protocol).

Tested on Kubuntu 11.10.

I couldn't find this in bugs.kde.org. Should someone file it as a bug?

Vianney
Vianney Stroebel
Registered Member
Posts
4
Karma
0
OS
FWIW: this issue was mentionned in this thread: viewtopic.php?f=64&t=98880&p=212389, with no follow-up.

Vianney
Vianney Stroebel
Registered Member
Posts
4
Karma
0
OS
freininghaus
Moderator
Posts
224
Karma
1
OS
Vianney Stroebel wrote:Should someone file it as a bug?


Probably yes, but we should try and find out what code is responsible first to make sure that the bug report goes to the right person. I'm a bit busy right now, but I'll try to have a look and then tell you about it during the next week (please ping me in a week if I forget to do it).


Bookmarks



Who is online

Registered users: bancha, Bing [Bot], daret, Evergrowing, Google [Bot], lockheed, mesutakcan, sandyvee, Sogou [Bot]