We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 72b8217 commit 7c898ffCopy full SHA for 7c898ff
1 file changed
src/flows/monitors/ghost_users.py
@@ -6,7 +6,8 @@
6
@ohld complained.
7
8
Definition: a ghost is a `user` row created N seconds ago with no
9
-`user_meme_reaction` row. Two severities, both filtered by
+`user_meme_reaction` row, excluding users who have blocked the bot.
10
+Two severities, both filtered by
11
`user_tg.deep_link` to exclude blocked acquisition channels (where
12
silent drop is by design):
13
@@ -71,6 +72,7 @@ def _ghost_count_sql() -> str:
71
72
WHERE u.created_at BETWEEN NOW() - INTERVAL '25 minutes'
73
AND NOW() - INTERVAL '60 seconds'
74
AND u.type NOT IN ('blocked_bot', 'banned', 'waitlist')
75
+ AND u.blocked_bot_at IS NULL
76
AND NOT EXISTS (
77
SELECT 1 FROM user_meme_reaction r WHERE r.user_id = u.id
78
)
0 commit comments