This patch gets rid of the last bits db initialization within db.py.
Everything is now done in create_db.

This fixes a bug I ran into where a script with read-only access to
db.py tried to connect to a new database.  Things would remain broken
(returning silly errors) until a script with read-write access ran
(and finished initialization).  IMHO, this is a cleaner way to do
things anyway.

From: Jeremy Orlow <jorlow@google.com>
Signed-off-by: Martin J. Bligh <mbligh@google.com>



git-svn-id: http://test.kernel.org/svn/autotest/trunk@740 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/client/bin/job.py b/client/bin/job.py
index fd010e0..ea19344 100755
--- a/client/bin/job.py
+++ b/client/bin/job.py
@@ -230,6 +230,12 @@
 			del dargs['tag']
 			if tag:
 				subdir += '.' + tag
+
+		reraise = False
+		if dargs.has_key('reraise'):
+			reraise = dargs['reraise']
+			del dargs['reraise']
+
 		try:
 			try:
 				self.__runtest(url, tag, args, dargs)
@@ -242,7 +248,10 @@
 				self.record('GOOD', subdir, testname, \
 						'completed successfully')
 		except TestError:
-			return 0
+			if reraise:
+				raise
+			else:
+				return 0
 		except:
 			raise
 		else: