2 # vim: set et sw=4 sts=4 encoding=utf-8 foldmethod=marker :
6 import turbogears.database
7 turbogears.update_config(configfile="dev.cfg", modulename="sercom.config")
9 __builtins__._ = turbogears.i18n.plain_gettext # Nada de gettext lazy
12 from sercom.tester import Tester
13 from sercom.model import Entrega, hub
14 from os.path import join
15 from datetime import datetime
19 log = logging.getLogger('sercom.tester')
29 e = Entrega.selectBy(inicio=None).orderBy(Entrega.q.fecha)[0]
30 e.inicio = datetime.now()
35 log.debug(_(u'No hay entregas pendientes'))
36 time.sleep(5) # TODO config?
38 if isinstance(e, SystemExit):
40 log.exception('Queue: ')
45 tester = Tester(name='pepe', path='var', home=join('home', 'sercom'), queue=q)