diff --git a/api/chalicelib/core/alerts_processor.py b/api/chalicelib/core/alerts_processor.py index f9604658b..2ed9105b2 100644 --- a/api/chalicelib/core/alerts_processor.py +++ b/api/chalicelib/core/alerts_processor.py @@ -196,7 +196,7 @@ def process(): cur.execute(query) result = cur.fetchone() if result["valid"]: - logging.info("Valid alert, notifying users, alertId:{alert['alertId']} name: {alert['name']}") + logging.info(f"Valid alert, notifying users, alertId:{alert['alertId']} name: {alert['name']}") notifications.append(generate_notification(alert, result)) except Exception as e: logging.error(f"!!!Error while running alert query for alertId:{alert['alertId']} name: {alert['name']}") diff --git a/api/chalicelib/core/collaboration_slack.py b/api/chalicelib/core/collaboration_slack.py index 15f090f5d..5e7797430 100644 --- a/api/chalicelib/core/collaboration_slack.py +++ b/api/chalicelib/core/collaboration_slack.py @@ -99,7 +99,8 @@ class Slack: url=integration["endpoint"], json={"attachments": attachments[i:i + 100]}) if r.status_code != 200: - print("!!!! something went wrong") + print("!!!! something went wrong while sending to:") + print(integration) print(r) print(r.text) diff --git a/ee/api/chalicelib/core/alerts_processor.py b/ee/api/chalicelib/core/alerts_processor.py index d45d3c464..087f23a05 100644 --- a/ee/api/chalicelib/core/alerts_processor.py +++ b/ee/api/chalicelib/core/alerts_processor.py @@ -201,7 +201,7 @@ def process(): cur.execute(query) result = cur.fetchone() if result["valid"]: - logging.info("Valid alert, notifying users, alertId:{alert['alertId']} name: {alert['name']}") + logging.info(f"Valid alert, notifying users, alertId:{alert['alertId']} name: {alert['name']}") notifications.append(generate_notification(alert, result)) except Exception as e: logging.error(f"!!!Error while running alert query for alertId:{alert['alertId']} name: {alert['name']}") diff --git a/ee/api/chalicelib/core/sessions_exp.py b/ee/api/chalicelib/core/sessions_exp.py index 075304ab7..0b77563f9 100644 --- a/ee/api/chalicelib/core/sessions_exp.py +++ b/ee/api/chalicelib/core/sessions_exp.py @@ -294,6 +294,7 @@ def search_sessions(data: schemas.SessionsSearchPayloadSchema, project_id, user_ sessions = cur.execute(main_query) except Exception as err: print("--------- SESSIONS-CH SEARCH QUERY EXCEPTION -----------") + print(main_query) print("--------- PAYLOAD -----------") print(data.json()) print("--------------------")