What takes time is not fixing the bugs, it is reading emails and
reproducing the errors.
If your email is short and to the point and contains enough code that
runs out of the box and reproduces the bug, it is easy to fix.
This was the case.

massimo

On Sep 8, 9:41 am, Jim Steil <[email protected]> wrote:
> Fixed - Thanks Massimo, that was fast!
>
>      -Jim
>
> http://code.google.com/p/web2py/issues/detail?id=412
>
> On 9/7/2011 4:30 PM, Jim Steil wrote:
>
>
>
>
>
>
>
> > Submitted -http://code.google.com/p/web2py/issues/detail?id=412
>
> >     -Jim
>
> > On 9/7/2011 4:25 PM, Mart�n Mulone wrote:
> >> I think is a bug, please report it:
> >>http://code.google.com/p/web2py/issues/list
>
> >> 2011/9/7 Jim Steil <[email protected] <mailto:[email protected]>>
>
> >>     Hi
>
> >>     I'm getting the following:
>
> >>     Traceback(most recent call last):
> >>        File"C:\dev\trunk\web2py\gluon\restricted.py",line194,inrestricted
> >>          execccodeinenvironment
> >>        
> >> File"C:/dev/trunk/web2py/applications/FoodPantry/controllers/default.py"  
> >> <http://192.168.1.171:8000/admin/default/edit/FoodPantry/controllers/d...>,line25,in<module>
> >>        File"C:\dev\trunk\web2py\gluon\globals.py",line145,in<lambda>
> >>          self._caller=lambdaf:f()
> >>        
> >> File"C:/dev/trunk/web2py/applications/FoodPantry/controllers/default.py"  
> >> <http://192.168.1.171:8000/admin/default/edit/FoodPantry/controllers/d...>,line21,inpersons
> >>          form=SQLFORM.grid(db.person,ui='jquery-ui',paginate=20)
> >>        File"C:\dev\trunk\web2py\gluon\sqlhtml.py",line1655,ingrid
> >>          id=row[field_id]
> >>        File"C:\dev\trunk\web2py\gluon\dal.py",line3832,in__getitem__
> >>          returndict.__getitem__(self,m.group(1))[m.group(2)]
> >>     TypeError:'Set'objectisunsubscriptable
>
> >>     with the the following setup:
>
> >>     db.py
> >>     person = db.define_table('person',
> >>         Field('personId', 'id'),
> >>         Field('firstName', length=25, required=True, label='First Name'),
> >>         Field('lastName', length=25, required=True, label='Last Name'),
> >>         Field('address', 'text'),
> >>         Field('city', length=30),
> >>         Field('state', length=2),
> >>         Field('zipCode', length=10, label='ZIP Code'),
> >>         Field('phone', length=25),
> >>         Field('dob', 'date', label='Date of Birth'),
> >>         Field('sex', length=1),
> >>         Field('disability', length=50),
> >>         Field('singleParent', 'boolean', default=False, label='Single
> >>     Parent'),
> >>         Field('healthInsurance', length=50, label='Health Insurance'),
> >>         Field('origin', length=50),
> >>         Field('headOfHousehold', 'reference person', label='Head of
> >>     Household'),
> >>         Field('lastFirst', compute=lambda u: '%s, %s' % (u['lastName'],
>
> >>     u['firstName'])))
> >>     person.firstName.requires = IS_NOT_EMPTY()
> >>     person.lastName.requires = IS_NOT_EMPTY()
> >>     person.dob.requires = IS_DATE()
> >>     person.sex.requires = IS_IN_SET(['M', 'F'])
> >>     person.headOfHousehold.requires = IS_EMPTY_OR(IS_IN_DB(db, db.person,
>
> >>     '%(lastFirst)s',
>
> >>     zero='...choose one...'))
>
> >>     default.py
>
> >>     def persons():
> >>         form = SQLFORM.grid(db.person, ui='jquery-ui', paginate=20)
>
> >>         return dict(form=form)
>
> >>     Any thoughts?
>
> >>         -Jim
>
> >> --
> >>http://martin.tecnodoc.com.ar

Reply via email to