Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't execute (open) files if provider is URI based #419

Open
cmallwitz opened this issue May 28, 2020 · 0 comments · May be fixed by #482
Open

Can't execute (open) files if provider is URI based #419

cmallwitz opened this issue May 28, 2020 · 0 comments · May be fixed by #482
Labels
Milestone

Comments

@cmallwitz
Copy link
Contributor

Using latest develop branch on Ubuntu 19.10, I can't open (double clicking) files in external application.

How to reproduce:

  • open ftp://[email protected]/ in Nautilus to mount it in Gnome
  • in Sunflower from context menu, "Enter path.." ftp://[email protected]/
  • Sunflower will display content of FTP directory
  • navigate to e.g. /pub/vim/
  • double click file "green_ball.gif" (at end)
  • this launches external image viewer but with an error that it can't find the file

I had a break point here:

  File "/home/christian/tech/IdeaProjects/Sunflower/sunflower/__main__.py", line 224, in <module>
    exit_status = application.run(sys.argv)
  File "/usr/lib/python3/dist-packages/gi/overrides/Gio.py", line 44, in run
    return Gio.Application.run(self, *args, **kwargs)
  File "/home/christian/tech/IdeaProjects/Sunflower/sunflower/plugin_base/item_list.py", line 528, in _handle_button_press
    self._execute_selected_item(widget)
  File "/home/christian/tech/IdeaProjects/Sunflower/sunflower/plugins/file_list/file_list.py", line 468, in _execute_selected_item
    self._parent.associations_manager.execute_file(selected_file, provider=self.get_provider())
  File "/home/christian/tech/IdeaProjects/Sunflower/sunflower/associations.py", line 314, in execute_file
    self.open_file((path,), default_application)
  File "/home/christian/tech/IdeaProjects/Sunflower/sunflower/associations.py", line 212, in open_file
    if application_info is not None:

In open_file()

  • argument selection {tuple: 1} 'ftp://[email protected]/pub/vim/green_ball.gif'
  • application (Gio.DesktopAppInfo) is retrieved with application.supports_uris() = True
  • convert selection to {list} ['file://ftp%3A//anonymous%40ftp.mirrorservice.org/pub/vim/green_ball.gif']

You can see the selection has an incorrect path for the external image viewer. The same happens if double clicking on files on a Samba share were the base URI is smb://...

@MeanEYE MeanEYE added the bug label May 29, 2020
@MeanEYE MeanEYE added this to the v0.5 milestone May 29, 2020
@joshas joshas linked a pull request Oct 15, 2020 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants