fix(dark-tariff): throttle repeated check_start brute-force attempts

This commit is contained in:
takuya committed 2026-11-29 13:47:57 +03:00
1 parent d8a89610cd
commit f5083397e6
3 files changed
+15 -3

No files matched your search

+6
View File
@@ -47,6 +47,12 @@ async def chat_greeting():
async def check_start(reading_id):
return await call("select chat.check_start(%s::bigint)", (reading_id,))
async def incomplete_checks(reading_id):
return await call(
"select count(*) from chat.check_session where reading_id = %s::bigint and not complete",
(reading_id,),
)
async def check_commit(check_id, round, values):
return await call("select chat.check_commit(%s::uuid, %s::int, %s::text[])", (check_id, round, values))