Report the slave is still alive when there is no revisions to benchmark

This commit is contained in:
Hannes Verschore 2014-01-03 15:30:58 +01:00
Родитель 463c1b92ae
Коммит 73d7e91467
2 изменённых файлов: 11 добавлений и 2 удалений

Просмотреть файл

@ -39,7 +39,6 @@ KnownEngines = [
builders.Nitro()
]
Engines = []
MozillaUpdated = False
NumUpdated = 0
for e in KnownEngines:
try:
@ -54,7 +53,12 @@ for e in KnownEngines:
NumUpdated += 1
Engines.append([e, cset, updated])
submit = submitter.Submitter()
# No updates. Report to server and wait 60 seconds, before moving on
if NumUpdated == 0 and not options.force:
submit.Awake();
sleep(60)
sys.exit(0)
# The native compiler is a special thing, for now.
@ -85,7 +89,6 @@ for entry in Engines:
modes.append(mode)
# Inform AWFY of each mode we found.
submit = submitter.Submitter()
submit.Start()
for mode in modes:
submit.AddEngine(mode.name, mode.cset)

Просмотреть файл

@ -13,6 +13,12 @@ class Submitter:
self.url = utils.config.get('main', 'updateURL')
self.machine = utils.config.get('main', 'machine')
def Awake(self):
url = self.url
url += '?awake=yes'
url += '&MACHINE=' + str(self.machine)
urllib2.urlopen(url)
def Start(self):
url = self.url
url += '?run=yes'