olive-gtk leaves user in the dark with file permissions crash

Bug #229044 reported by dn
16
Affects Status Importance Assigned to Milestone
Bazaar
Fix Released
Medium
Unassigned
Bazaar GTK+ Frontends
Fix Released
Medium
Jasper Groenewegen
bzr (Ubuntu)
Invalid
Undecided
Unassigned
bzr-gtk (Ubuntu)
Invalid
Medium
Jasper Groenewegen

Bug Description

Binary package hint: bzr-gtk

When I tried to navigate to /etc with bzr-gtk 0.93.0 (Olive), it presented a crash message ("The program olive-gtk closed unexpectedly") when trying to read the file /etc/.etckeeper. The file was apparently owned by root and set to unreadable by anyone else [presumably because etckeeper always runs its chosen VCS as root when it's triggered by apt]. So it's caused by a separate problem with etckeeper I should probably look up or file as a bug, but Olive ought to be a little more informative when file permissions rear their ugly head--I had to look into the traceback to find out what the problem was.

The Olive GUI survived the crash by 'olive-gtk' and was still useable, but I can't access the repository in /etc at all without changing the file permissions on that one file, and it really should tell less-savvy users that they need to do that.

ProblemType: Crash
Architecture: i386
Date: Sat May 10 13:22:02 2008
DistroRelease: Ubuntu 8.04
ExecutablePath: /usr/bin/olive-gtk
InterpreterPath: /usr/bin/python2.5
NonfreeKernelModules: fglrx
Package: bzr-gtk 0.93.0-1
PackageArchitecture: all
ProcCmdline: /usr/bin/python /usr/bin/olive-gtk
ProcEnviron:
 PATH=/home/username/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
 LANG=en_US.UTF-8
 SHELL=/bin/bash
PythonArgs: ['/usr/bin/olive-gtk']
SourcePackage: bzr-gtk
Title: olive-gtk crashed with OSError in _walkdirs_fs_utf8()
Uname: Linux 2.6.24-16-generic i686
UserGroups: adm admin audio cdrom dialout dip floppy kvm lpadmin netdev plugdev powerdev scanner video

Revision history for this message
dn (nobled) wrote :
Revision history for this message
Kristofer Pettersson (kristofer-pettersson-sun) wrote :

I've got a similar crash at start up:

Traceback (most recent call last):
  File "/usr/bin/olive-gtk", line 94, in <module>
    app = OliveGtk()
  File "/usr/lib/python2.5/site-packages/olive/__init__.py", line 248, in __init__
    self._load_right()
  File "/usr/lib/python2.5/site-packages/olive/__init__.py", line 1026, in _load_right
    statinfo = os.stat(self.path + os.sep + item)
OSError: [Errno 2] No such file or directory: <snip>

Apparently there was a broken symlink in my home directory. Removing that link enabled Olive to start.

Jelmer Vernooij (jelmer)
Changed in bzr-gtk:
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Jasper Groenewegen (colbrac) wrote :

This is not a duplicate of 125144!
125144 is about the broken symlink causing a crash
this one is about a non-readable .bzr folder causing a crash

With current trunk:
Traceback (most recent call last):
  File "/home/jasper/.bazaar/plugins/gtk/olive/__init__.py", line 323, in on_button_location_jump_clicked
    if self.set_path(location):
  File "/home/jasper/.bazaar/plugins/gtk/olive/__init__.py", line 215, in set_path
    self.wt, self.wtpath = WorkingTree.open_containing(path)
  File "/usr/lib/python2.5/site-packages/bzrlib/workingtree.py", line 325, in open_containing
    control, relpath = bzrdir.BzrDir.open_containing(path)
  File "/usr/lib/python2.5/site-packages/bzrlib/bzrdir.py", line 825, in open_containing
    return BzrDir.open_containing_from_transport(transport)
  File "/usr/lib/python2.5/site-packages/bzrlib/bzrdir.py", line 846, in open_containing_from_transport
    result = BzrDir.open_from_transport(a_transport)
  File "/usr/lib/python2.5/site-packages/bzrlib/bzrdir.py", line 800, in open_from_transport
    redirected)
  File "/usr/lib/python2.5/site-packages/bzrlib/transport/__init__.py", line 1616, in do_catching_redirections
    return action(transport)
  File "/usr/lib/python2.5/site-packages/bzrlib/bzrdir.py", line 777, in find_format
    transport, _server_formats=_server_formats)
  File "/usr/lib/python2.5/site-packages/bzrlib/bzrdir.py", line 1569, in find_format
    return format.probe_transport(transport)
  File "/usr/lib/python2.5/site-packages/bzrlib/bzrdir.py", line 1579, in probe_transport
    format_string = transport.get(".bzr/branch-format").read()
  File "/usr/lib/python2.5/site-packages/bzrlib/transport/local.py", line 147, in get
    self._translate_error(e, path)
  File "/usr/lib/python2.5/site-packages/bzrlib/transport/__init__.py", line 316, in _translate_error
    raise errors.PermissionDenied(path, extra=e)
bzrlib.errors.PermissionDenied: Permission denied: "/etc/.bzr/branch-format": [Errno 13] Permission denied: u'/etc/.bzr/branch-format'

And from a terminal:
/etc$ bzr status
bzr: ERROR: Permission denied: "/etc/.bzr/branch-format": [Errno 13] Permission denied: u'/etc/.bzr/branch-format'

So, Olive should catch the permission denied error when trying to open a non-readable .bzr folder, show a warning message stating so and loading the offending folder like an ordinary folder.

Revision history for this message
Gediminas Paulauskas (menesis) wrote :

OK so only the 2nd comment is about bug #125144.
I'm not sure your comment and the report are about the same problem. But either way it is a bug in bzr, not olive.

Revision history for this message
James Westby (james-w) wrote :

Hi,

I disagree that this is a problem in bzr. It's been asked to open a branch
and can't. If bzr-gtk wants to handle that case it should, but bzr shouldn't
silently do nothing when asked to open a branch that it can't.

Thanks,

James

Changed in bzr:
status: Triaged → Invalid
status: New → Invalid
Changed in bzr-gtk:
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Jasper Groenewegen (colbrac) wrote :

Ok, enough already. I will fix this ok?

Changed in bzr-gtk:
assignee: nobody → colbrac
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Jasper Groenewegen (colbrac) wrote :

This is an upstream issue

Changed in bzr-gtk:
assignee: nobody → colbrac
status: Triaged → Invalid
Revision history for this message
Jasper Groenewegen (colbrac) wrote :

Patch send to mailing list

Changed in bzr-gtk:
milestone: none → 0.95.0
status: Triaged → In Progress
Revision history for this message
Jasper Groenewegen (colbrac) wrote :

Fix committed to trunk as rev 586.

Changed in bzr-gtk:
status: In Progress → Fix Committed
Jelmer Vernooij (jelmer)
Changed in bzr:
status: Invalid → Fix Released
Changed in bzr-gtk:
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.