famous last words: UnboundLocalError thumbheight

Bug #535381 reported by Bratix
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
phraymd
Fix Released
Critical
dmoore

Bug Description

After creating a new collection the verify job starts,
but dies with these last words:

Traceback (most recent call last):
  File "/home/cbra/develop/phraymd/phraymd/modules/phraymd/browser.py", line 588, in expose_signal
    self.realize_signal(event)
  File "/home/cbra/develop/phraymd/phraymd/modules/phraymd/browser.py", line 694, in realize_signal
    overlay_height=int(y+self.geo_pad/2+thumbheight+(self.geo_thumbheight-thumbheight)/2-ly)
UnboundLocalError: local variable 'thumbheight' referenced before assignment

look at the added line below:

Regards
Bratix

=== modified file 'modules/phraymd/browser.py'
--- modules/phraymd/browser.py 2010-03-08 23:31:32 +0000
+++ modules/phraymd/browser.py 2010-03-09 22:21:33 +0000
@@ -668,6 +668,7 @@
                 adjx=self.geo_pad/2+(128-thumbwidth)/2
                 drawable.draw_pixbuf(gc, item.thumb, 0, 0,int(x+adjx),int(y+adjy))
             elif item.cannot_thumb:
+ (thumbwidth,thumbheight)=(0,0)
                 adjy=self.geo_pad/2
                 adjx=self.geo_pad/2
                 drawable.draw_pixbuf(gc, self.pixbuf_thumb_fail, 0, 0,int(x+adjx),int(y+adjy))

Revision history for this message
dmoore (damien-moore) wrote : Re: [Bug 535381] [NEW] famous last words: UnboundLocalError thumbheight

thanks for the report and patch. I'll commit soon.

On Tue, Mar 9, 2010 at 5:24 PM, Bratix <email address hidden> wrote:
> Public bug reported:
>
> After creating a new collection the verify job starts,
> but dies with these last words:
>
> Traceback (most recent call last):
>  File "/home/cbra/develop/phraymd/phraymd/modules/phraymd/browser.py", line 588, in expose_signal
>    self.realize_signal(event)
>  File "/home/cbra/develop/phraymd/phraymd/modules/phraymd/browser.py", line 694, in realize_signal
>    overlay_height=int(y+self.geo_pad/2+thumbheight+(self.geo_thumbheight-thumbheight)/2-ly)
> UnboundLocalError: local variable 'thumbheight' referenced before assignment
>
> look at the added line below:
>
> Regards
> Bratix
>
> === modified file 'modules/phraymd/browser.py'
> --- modules/phraymd/browser.py  2010-03-08 23:31:32 +0000
> +++ modules/phraymd/browser.py  2010-03-09 22:21:33 +0000
> @@ -668,6 +668,7 @@
>                 adjx=self.geo_pad/2+(128-thumbwidth)/2
>                 drawable.draw_pixbuf(gc, item.thumb, 0, 0,int(x+adjx),int(y+adjy))
>             elif item.cannot_thumb:
> +                (thumbwidth,thumbheight)=(0,0)
>                 adjy=self.geo_pad/2
>                 adjx=self.geo_pad/2
>                 drawable.draw_pixbuf(gc, self.pixbuf_thumb_fail, 0, 0,int(x+adjx),int(y+adjy))
>
> ** Affects: phraymd
>     Importance: Undecided
>         Status: New
>
> --
> famous last words: UnboundLocalError thumbheight
> https://bugs.launchpad.net/bugs/535381
> You received this bug notification because you are subscribed to
> phraymd.
>

dmoore (damien-moore)
Changed in phraymd:
status: New → Fix Committed
importance: Undecided → Critical
assignee: nobody → spillz (damien-moore)
antistress (antistress)
Changed in phraymd:
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.