Please send the whole default.py as I don't think do problem is on that
line you showed.
Kenneth
Can somebody please explain what the issue is. Its this video at 9.34:
http://vimeo.com/6507384
TRACEBACK
Traceback (most recent call last):
File "gluon/restricted.py", line 192, in restricted
File "C:/Users/Joe/Desktop/P/web2py/applications/polls/controllers/
default.py", line 73, in<module>
File "gluon/globals.py", line 137, in<lambda>
File "C:/Users/Joe/Desktop/P/web2py/applications/polls/controllers/
default.py", line 17, in index
TypeError: bad operand type for unary -: 'Field'
ERROR SNAPSHOT
<type 'exceptions.TypeError'>(bad operand type for unary -: 'Field')
Code listing
def index():
latest_poll_list = db(db.poll.id>0).select(orderby=
db.poll.pub_date, limitby=(0,5)) # this is the line with the apparent
problem
return dict(latest_poll_list=latest_poll_list)
def user():