#NEWLINE# def get_entries( executor ) : #NEWLINE# #INDENT# entries = executor ( '\n        SELECT * FROM bayesdb_session_entries ORDER BY id\n    ' ) #NEWLINE# fields = [ 'id' , 'session_id' , 'type' , 'data' , 'start_time' , 'end_time' , 'error' ] #NEWLINE# assert ( fields == [ executor [ 0 ] for d in entries . description ] ) #NEWLINE# SessionEntry = namedtuple ( 'SessionEntry' , fields ) #NEWLINE# return [ SessionEntry ( * e ) for e in entries ]