digital clock applet is not multi-user-friendly
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Awn Extras |
Fix Released
|
Medium
|
Mark Lee |
Bug Description
The digital clock applet only works for the first user that logs in (until a restart). For every other user, the applet will crash.
I suppose the problem is that the applet creates an image with a hardcoded filename in the global temp directory, which is then only writable by the user that created it.
The bug applies to the package avant-window-
Traceback (most recent call last):
File "/usr/lib/
applet = App (awn.uid, awn.orient, awn.height)
File "/usr/lib/
self.clock = dgTime.
File "/usr/lib/
self.
File "/usr/lib/
cs.write_to_png (self.tmp_image)
IOError: error while writing to output stream
Changed in awn-extras: | |
assignee: | nobody → ryancr |
importance: | Undecided → Medium |
milestone: | none → 0.2.8 |
status: | New → Confirmed |
Changed in awn-extras: | |
status: | Fix Committed → Fix Released |
I found a fix. As awn is started in a different process for each user, it works to insert the process ID in the filename:
Change dgTime.py:14 to the following:
tmp_image = os.path. join(tmp_ dir, 'digitalclock. %s.png' % os.getpid())