Up threshold for sms to telephone numbers

We were just ignoring the errors and our users were not fixing things.

Given that 500 texts cost approx £8 it's not the end of the world.

In the long run we may decide to just stop letting people try and send
messages to TV numbers but this is a quick fix to stop emails coming in
which we ignore.
This commit is contained in:
David McDonald
2020-01-17 11:30:19 +00:00
parent 879ba1d5f0
commit 3a0aece6a1
3 changed files with 3 additions and 3 deletions

View File

@@ -286,7 +286,7 @@ def check_for_services_with_high_failure_rates_or_sending_to_tv_numbers():
)
message += "service: {} failure rate: {},\n".format(service_dashboard, service.permanent_failure_rate)
elif services_sending_to_tv_numbers:
message += "{} service(s) have sent over 100 sms messages to tv numbers in last 24 hours:\n".format(
message += "{} service(s) have sent over 500 sms messages to tv numbers in last 24 hours:\n".format(
len(services_sending_to_tv_numbers)
)
for service in services_sending_to_tv_numbers:

View File

@@ -525,7 +525,7 @@ def dao_fetch_active_users_for_service(service_id):
return query.all()
def dao_find_services_sending_to_tv_numbers(start_date, end_date, threshold=100):
def dao_find_services_sending_to_tv_numbers(start_date, end_date, threshold=500):
return db.session.query(
Notification.service_id.label('service_id'),
func.count(Notification.id).label('notification_count')