diff options
author | Rob Austein <sra@hactrn.net> | 2011-10-05 16:30:24 +0000 |
---|---|---|
committer | Rob Austein <sra@hactrn.net> | 2011-10-05 16:30:24 +0000 |
commit | 72e42a6508ff19a315a0257dda4a710bc195dffa (patch) | |
tree | 34785d51be76bdb31b72784dd527125145b1ebc9 /rpkid/tests/smoketest.py | |
parent | 03d8dcaf85e21fe621f020c4fb34fdecb6ac4cca (diff) |
Add global traceback control; this closes #95. Clean up some
"except:" clauses that should have been "except Exception:".
svn path=/rpkid/rpki-sql-setup.py; revision=4014
Diffstat (limited to 'rpkid/tests/smoketest.py')
-rw-r--r-- | rpkid/tests/smoketest.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/rpkid/tests/smoketest.py b/rpkid/tests/smoketest.py index bcb6d699..127e3f79 100644 --- a/rpkid/tests/smoketest.py +++ b/rpkid/tests/smoketest.py @@ -82,7 +82,7 @@ if yaml_script is None: yaml_script = cfg.get("yaml_script", "smoketest.yaml") try: yaml_script = [y for y in yaml.safe_load_all(open(yaml_script))] -except: +except Exception: print __doc__ raise @@ -704,7 +704,7 @@ class allocation(object): for sql in rpki_sql: try: cur.execute(sql) - except: + except Exception: if not sql.upper().startswith("DROP TABLE"): raise db.close() @@ -714,7 +714,7 @@ class allocation(object): for sql in irdb_sql: try: cur.execute(sql) - except: + except Exception: if not sql.upper().startswith("DROP TABLE"): raise for s in [self] + self.hosts: @@ -1170,7 +1170,7 @@ def setup_publication(pubd_sql): for sql in pubd_sql: try: cur.execute(sql) - except: + except Exception: if not sql.upper().startswith("DROP TABLE"): raise db.close() |