politica de DMs r33: urgent-watch solo 4 clases + tope 3/dia + dedup tipo:sujeto 24h + backup 2 dias; reporte diario con conteo de DMs y diferidos
ci / lint-test (pull_request) Successful in 1s
isolation-test / probe (pull_request) Successful in 1s

This commit is contained in:
coder-agent
2026-11-03 16:23:08 +00:00
parent 6e16965e9b
commit 91480ebb1a
2 changed files with 151 additions and 0 deletions
+13
View File
@@ -39,6 +39,19 @@ WHERE ts > now() - interval '24 hours'
GROUP BY reasons ORDER BY count(*) DESC LIMIT 6;
EOF
echo ""
echo "== 2b. DMs urgentes (politica r33) =="
NDM=$(journalctl -u cayce-nostr --since "-24 hours" --no-pager 2>/dev/null | grep -c "\[dm\] envio a")
UCOUNT=$(python3 -c "import json; print(json.load(open('/srv/cayce-core/.dm-urgent-count.json')).get('$(date -u +%F)', 0))" 2>/dev/null || echo 0)
echo " DMs NIP-04 enviados (24h, todas las causas): $NDM · urgentes de hoy (tope 3): $UCOUNT"
if [ -s /srv/cayce-core/.dm-deferred.log ]; then
echo " diferidos por tope (van aqui en vez de DM):"
tail -5 /srv/cayce-core/.dm-deferred.log | sed "s/^/ /"
fi
if [ -f /srv/cayce-core/PUBLISH_OFF ]; then
echo " kill switch: ACTIVO ($(head -c 20 /srv/cayce-core/PUBLISH_OFF 2>/dev/null))"
fi
echo ""
echo "== 3. PRs y deploys =="
BTOK=$(cat /etc/cayce/ci-bot.token 2>/dev/null)