diff options
author | jasplin <qt-info@nokia.com> | 2011-02-24 12:21:34 +0100 |
---|---|---|
committer | jasplin <qt-info@nokia.com> | 2011-02-24 12:21:34 +0100 |
commit | 7fe851cf98d118579c34d1a0558d8ab772f59e81 (patch) | |
tree | 99e4308e6a54cb77386b67125e3e3bcbc4c1a2ba | |
parent | 8797dee5b8624b69bbf914e5682acb8e9285ea60 (diff) |
Minor cleanup.
-rwxr-xr-x | scripts/finalizeresults.py | 8 | ||||
-rwxr-xr-x | scripts/getstats.py | 8 | ||||
-rwxr-xr-x | scripts/runtests.py | 9 | ||||
-rwxr-xr-x | scripts/uploadresults.py | 8 |
4 files changed, 25 insertions, 8 deletions
diff --git a/scripts/finalizeresults.py b/scripts/finalizeresults.py index c335de2..2ff9a45 100755 --- a/scripts/finalizeresults.py +++ b/scripts/finalizeresults.py @@ -7,7 +7,7 @@ from misc import ( isValidSHA1, getBMTimeSeriesStatsList) -# === Global functions =============================================== +# --- BEGIN Global functions ---------------------------------------------- def printUsage(): print ( @@ -294,8 +294,10 @@ def updateRankings(host_id, platform_id, branch_id, sha12_id, context2_id): sys.stdout.write("\n") +# --- END Global functions ---------------------------------------------- -# === Main program =================================================== + +# --- BEGIN Main program ---------------------------------------------- options, http_get = getOptions() @@ -346,3 +348,5 @@ updateRankings(host_id, platform_id, branch_id, sha12_id, context2_id) commit() print "finalization done" + +# --- END Main program ---------------------------------------------- diff --git a/scripts/getstats.py b/scripts/getstats.py index feb665a..d0b7d59 100755 --- a/scripts/getstats.py +++ b/scripts/getstats.py @@ -16,7 +16,7 @@ from dbaccess import setDatabase from misc import getOptions, printErrorAsJSON import sys -# === Global functions =============================================== +# --- BEGIN Global functions ---------------------------------------------- # Returns a command instance. def createCommand(options, http_get): @@ -294,9 +294,13 @@ def createCommand(options, http_get): printUsageError() sys.exit(1) +# --- END Global functions ---------------------------------------------- -# === Main program =================================================== + +# --- BEGIN Main program ---------------------------------------------- options, http_get = getOptions() command = createCommand(options, http_get) command.execute() + +# --- END Main program ---------------------------------------------- diff --git a/scripts/runtests.py b/scripts/runtests.py index 2de9cc9..17349b0 100755 --- a/scripts/runtests.py +++ b/scripts/runtests.py @@ -20,7 +20,7 @@ import os from subprocess import Popen, PIPE from datetime import datetime -# === Global functions =================================================== +# --- BEGIN Global functions ---------------------------------------------- def printUsage(): print( @@ -123,7 +123,10 @@ def uploadResults(prog, host, platform, branch, sha1, timestamp, results_file): if (err_msg != ""): raise Exception(err_msg) -# === Main program =================================================== +# --- END Global functions ---------------------------------------------- + + +# --- BEGIN Main program ---------------------------------------------- args = getArgs() @@ -168,3 +171,5 @@ for run in range(nruns): print "failed:\n ", sys.exc_info() print "done" + +# --- END Main program ---------------------------------------------- diff --git a/scripts/uploadresults.py b/scripts/uploadresults.py index 9d22315..7f9c7f9 100755 --- a/scripts/uploadresults.py +++ b/scripts/uploadresults.py @@ -6,7 +6,7 @@ from dbaccess import setDatabase, execQuery, commit from misc import getOptions, isValidSHA1, getContext -# === Global functions =============================================== +# --- BEGIN Global functions ---------------------------------------------- def printUsage(): print ( @@ -240,8 +240,10 @@ def uploadToDatabase(dbhost, dbport, db, host, platform, branch, sha1, results): # Write to database: commit() +# --- END Global functions ---------------------------------------------- -# === Main program =================================================== + +# --- BEGIN Main program ---------------------------------------------- options, http_get = getOptions() @@ -271,3 +273,5 @@ uploadToDatabase( options["sha1"], results) print "uploading done" + +# --- END Main program ---------------------------------------------- |