Filemanager sending out file:/// URLs

Bug #1366217 reported by Ted Gould
32
This bug affects 4 people
Affects Status Importance Assigned to Milestone
Ubuntu File Manager App
Fix Released
High
Arto Jalkanen

Bug Description

It seems the file manager is sending file:/// URLs to the URL Dispatcher. Those are unlikely to work and generally a bad idea. For viewing files the file manager should be using the content hub.

https://errors.ubuntu.com/oops/ae7eff84-3529-11e4-aa89-fa163e707a72

Related branches

Revision history for this message
Carlos Jose Mazieri (carlos-mazieri) wrote :

File manager uses QDestktpServices::openUrl() to open files: http://bazaar.launchpad.net/~ubuntu-filemanager-dev/ubuntu-filemanager-app/trunk/view/head:/src/plugin/folderlistmodel/dirmodel.cpp#L1314

For files it uses file:/// prefix and it is necessary.

It looks like QDestktpServices::openUrl() is translated to the URL Dispatcher.

Is it what you are talking about?

Revision history for this message
Ted Gould (ted) wrote : Re: [Bug 1366217] Re: Filemanager sending out file:/// URLs

Correct, that's not a good way to open files. In general, file:/// urls
will not be handled as expected. The filemanager needs to use the
Content Hub to open files, not sending a URL to openUrl().

Revision history for this message
Ken VanDine (ken-vandine) wrote :

For opening local content, the filemanager should use the Content Hub's peer picker to choose a destination application to open the content with. However, this isn't terribly robust for an application like the filemanager than might not know the well known ContentType for a file. The filemanager will probably need to do some mapping of files to ContentType based on file extensions or some other heuristic, until the Content Hub supports mime types (which is planned).

Revision history for this message
Carlos Jose Mazieri (carlos-mazieri) wrote :

We need to open files, is it possible to keep that until Content Hub is not ready?

How about xdg open, is it available on phablet devices?

Revision history for this message
Ted Gould (ted) wrote :

On Mon, 2014-09-08 at 22:03 +0000, Carlos Jose Mazieri wrote:

> We need to open files, is it possible to keep that until Content Hub is
> not ready?

There's nothing to keep, it doesn't work. The only cases that'll work
today are videos in a specific directory and music in a specific
directory, and those will be dropped shortly. Otherwise there are no
files that are handled. Content hub is the solution here.

> How about xdg open, is it available on phablet devices?

No, it is not.

Changed in ubuntu-filemanager-app:
assignee: nobody → Carlos Jose Mazieri (carlos-mazieri)
Revision history for this message
Alan Pope 🍺🐧🐱 🦄 (popey) wrote :

Carlos, any progress on this? url-dispatcher has now been updated and opening files is now broken.

Changed in ubuntu-filemanager-app:
importance: Undecided → High
Revision history for this message
Carlos Jose Mazieri (carlos-mazieri) wrote :

Just started working on it, need to understand Content Hub's peer picker.

David Planella (dpm)
Changed in ubuntu-filemanager-app:
status: New → Triaged
Arto Jalkanen (ajalkane)
Changed in ubuntu-filemanager-app:
assignee: Carlos Jose Mazieri (carlos-mazieri) → Arto Jalkanen (ajalkane)
status: Triaged → In Progress
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :

Fix committed into lp:ubuntu-filemanager-app at revision 307, scheduled for release in ubuntu-filemanager-app, milestone alpha-1

Changed in ubuntu-filemanager-app:
status: In Progress → Fix Committed
Niklas Wenzel (nikwen)
Changed in ubuntu-filemanager-app:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.