Skip to content

Commit

Permalink
addressing andrey's comment
Browse files Browse the repository at this point in the history
  • Loading branch information
Greg Butzi authored and sfc-gh-afedorov committed Dec 6, 2018
1 parent 8308666 commit 05d7ffe
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/runners/alert_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def log_alerts(ctx, alerts):
something goes wrong.
"""
if len(alerts):
print("Logging alerts...")
print("Recording alerts.")
try:
ctx.cursor().execute(
f'''
Expand Down
2 changes: 1 addition & 1 deletion src/runners/alert_queries_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ def record_metadata(ctx, metadata):
PARSE_JSON(column1) from values('{json.dumps(metadata)}')
'''
try:
log.info("Recording run metadata...")
log.info("Recording run metadata.")
ctx.cursor().execute(statement)
except Exception as e:
log.fatal("Metadata failed to log", e)
Expand Down
4 changes: 2 additions & 2 deletions src/runners/alert_suppressions_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def log_alerts(ctx, alerts):
suppression fails to execute.
"""
if len(alerts):
print("Logging alerts...")
print("Recording alerts.")
format_string = ", ".join(["(%s)"] * len(alerts))
try:
ctx.cursor().execute(
Expand Down Expand Up @@ -123,7 +123,7 @@ def record_metadata(ctx, metadata):
PARSE_JSON(column1) from values('{json.dumps(metadata)}')
'''
try:
log.info("Recording run metadata...")
log.info("Recording run metadata.")
ctx.cursor().execute(statement)
except Exception as e:
log.fatal("Metadata failed to log", e)
Expand Down
2 changes: 1 addition & 1 deletion src/runners/violation_queries_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def record_metadata(ctx, metadata):
PARSE_JSON(column1) from values('{json.dumps(metadata)}')
'''
try:
log.info("Recording run metadata...")
log.info("Recording run metadata.")
ctx.cursor().execute(statement)
except Exception as e:
log.fatal("Metadata failed to log", e)
Expand Down
4 changes: 2 additions & 2 deletions src/runners/violation_suppressions_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def run_suppression(squelch_name):


def record_metadata(ctx, metadata):
metadata['RUN_START_TIME'] = str(metadata['RUN_START_TIME']) # We wantd them to be objects for mathing
metadata['RUN_START_TIME'] = str(metadata['RUN_START_TIME']) # We want them to be objects for mathing
metadata['RUN_END_TIME'] = str(metadata['RUN_END_TIME']) # then convert to string for json serializing
metadata['RUN_DURATION'] = str(metadata['RUN_DURATION'])

Expand All @@ -52,7 +52,7 @@ def record_metadata(ctx, metadata):
PARSE_JSON(column1) from values('{json.dumps(metadata)}')
'''
try:
log.info("Recording run metadata...")
log.info("Recording run metadata.")
ctx.cursor().execute(statement)
except Exception as e:
log.fatal("Metadata failed to log", e)
Expand Down

0 comments on commit 05d7ffe

Please sign in to comment.