make smart show non-cryptic error message on path noth available

Bug #245117 reported by Rehan Khan
2
Affects Status Importance Assigned to Milestone
Smart Package Manager
New
Wishlist
Unassigned

Bug Description

Imported: http://tracker.labix.org/issue366

Reason: Issue Review. Bug. Better file/error handling required?

further details: https://blueprints.launchpad.net/smart/+spec/bug-reporting-migration

msg1318 (view) Author: casualprogrammer Date: 2008-02-16.19:38:47

For space reasons I replaced the directory /var/lib/smart/packages/ with a
symbolic link to an external (firewire) drive with ample space.

While running smart update with the drive not present, smart issues the
following message:

Traceback (most recent call last):

  File "/usr/lib/python2.5/site-packages/smart/interfaces/gtk/interactive.py",
line 180, in callback
    exec code in globals

  File "<callback>", line 1, in <module>

  File "/usr/lib/python2.5/site-packages/smart/interfaces/gtk/interactive.py",
line 424, in applyChanges
    if self._ctrl.commitTransaction(transaction, confirm=confirm):

  File "/usr/lib/python2.5/site-packages/smart/control.py", line 500, in
commitTransaction
    return self.commitChangeSet(trans.getChangeSet(), caching, confirm)

  File "/usr/lib/python2.5/site-packages/smart/control.py", line 545, in
commitChangeSet
    caching)

  File "/usr/lib/python2.5/site-packages/smart/control.py", line 632, in
fetchPackages
    os.makedirs(localdir)

  File "/usr/lib/python2.5/os.py", line 172, in makedirs
    mkdir(name, mode)

OSError: [Errno 17] File exists: '/var/lib/smart/packages/'

While the last line is probably the result of smart not being able to create the
packages directory because of the existing link, it could state that a link
exists whose target is missing, instead of this correct but rather cryptic message.

Rehan Khan (rasker)
Changed in smart:
importance: Undecided → Wishlist
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.