I hesitate to call this a bug, as at my level of expertise that seems ... unlikely. But I can't think of any other explanation:
Call it 'typo' ;)
print "item[0] > lvl = %d > %d = " %(item[0], lvl), bool(item[0] == lvl)
use bool(item[0] > lvl)
HTH, Mike
-- http://mail.python.org/mailman/listinfo/python-list