[llvm-commits] [LNT] r161336 - in /lnt/trunk/lnt/server: config.py db/testsuitedb.py
Daniel Dunbar
daniel at zuster.org
Mon Aug 6 13:02:52 PDT 2012
Author: ddunbar
Date: Mon Aug 6 15:02:52 2012
New Revision: 161336
URL: http://llvm.org/viewvc/llvm-project?rev=161336&view=rev
Log:
Eliminate code for determining SimpleRunID in V4 databases.
Modified:
lnt/trunk/lnt/server/config.py
lnt/trunk/lnt/server/db/testsuitedb.py
Modified: lnt/trunk/lnt/server/config.py
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/server/config.py?rev=161336&r1=161335&r2=161336&view=diff
==============================================================================
--- lnt/trunk/lnt/server/config.py (original)
+++ lnt/trunk/lnt/server/config.py Mon Aug 6 15:02:52 2012
@@ -52,11 +52,10 @@
bool(dict.get('showSimple')),
str(dict.get('db_version', '0.3')),
dict.get('shadow_import', None),
- dict.get('simple_run_source', None),
email_config)
def __init__(self, path, showNightlytest, showGeneral, showSimple,
- db_version, shadow_import, simple_run_source, email_config):
+ db_version, shadow_import, email_config):
self.config = None
self.path = path
self.showGeneral = showGeneral
@@ -64,7 +63,6 @@
self.showSimple = showSimple
self.db_version = db_version
self.shadow_import = shadow_import
- self.simple_run_source = simple_run_source
self.email_config = email_config
class Config:
Modified: lnt/trunk/lnt/server/db/testsuitedb.py
URL: http://llvm.org/viewvc/llvm-project/lnt/trunk/lnt/server/db/testsuitedb.py?rev=161336&r1=161335&r2=161336&view=diff
==============================================================================
--- lnt/trunk/lnt/server/db/testsuitedb.py (original)
+++ lnt/trunk/lnt/server/db/testsuitedb.py Mon Aug 6 15:02:52 2012
@@ -619,40 +619,8 @@
self._importSampleValues(data['Tests'], run, tag)
- # If we have a config object and we have a database which we are
- # supposed to link simple/ runs from, attempt to find the matching run
- # in that database.
- if config and config.simple_run_source:
- self.find_and_set_simple_run_id(run, data, config)
-
return True, run
-
- def find_and_set_simple_run_id(self, run, data, config):
- # Get the database we are supposed to match run IDs in.
- db = config.config.get_database(config.simple_run_source)
-
- # Figure out the matching machine.
- simple_machine,created = db.getOrCreateMachine(
- data['Machine']['Name'], data['Machine']['Info'].items())
- if created:
- # Obviously missing, rollback and abort.
- db.rollback()
- return
-
- run_data = data['Run']
- simple_run,created = db.getOrCreateRun(
- simple_machine,
- run_data.get('Start Time',''), run_data.get('End Time',''),
- run_data['Info'].items())
- if created:
- # Obviously missing, rollback and abort.
- db.rollback()
- return
-
- # Otherwise, we found the run.
- run.simple_run_id = simple_run.id
-
# Simple query support (mostly used by templates)
def machines(self, name=None):
More information about the llvm-commits
mailing list