Skip to content

docs(dev): verify alerts guide against code and unmark migrated (#206) - #214

Merged
antiv merged 3 commits into
antiv:mainfrom
Fire162:docs/alerts-clean
Oct 11, 2026
Merged

antiv merged 3 commits into
antiv:mainfrom
Fire162:docs/alerts-clean

Conversation

@Fire162

@Fire162 Fire162 commented Oct 11, 2026

Copy link
Copy Markdown
Contributor

Part of #206.

Summary of Changes

  • Verified docs/dev/alerts.md against the underlying implementation files:
    • shared/utils/alert_service.py: confirmed environment variables (ALERTS_ENABLED, ALERTS_INTERVAL_SECONDS), condition types (agent_error_count, budget_threshold, guardrail_count), destinations (http, email), scopes (user, agent, project, global), and cooldown semantics (alert_rules.last_fired_at).
  • Removed status: migrated from frontmatter in docs/dev/alerts.md.
  • Ran python3 scripts/gen_docs.py --check (passes with 0 errors).

@antiv

antiv commented Oct 11, 2026

Copy link
Copy Markdown
Owner

Thanks. This PR only removes status: migrated, and the description lists 3 conditions and http/email only, which matches the guide as it was before 2c45cce rather than current main. On current main the guide is mostly right, but please add before unmarking:

  1. Dollar budgets: budget_threshold accepts "unit": "usd" with usd_limit (falls back to the rate-limit config), only for day/month and only for user, agent or project scope (_measure_usd_budget).
  2. A global budget rule never fires: _measure_budget returns None for that scope.
  3. covers: should include shared/utils/trigger_runner.py (scheduling, ALERTS_INTERVAL_SECONDS with a minimum of 10) and the alert routes in shared/utils/dashboard/dashboard_server.py.

Please also rebase on current main (the branch is 66 commits behind).

@Fire162

Fire162 commented Oct 11, 2026

Copy link
Copy Markdown
Contributor Author

Updated:

  • Re-checked docs/dev/alerts.md against latest main.
  • Documented dollar budgets: budget_threshold with "unit": "usd" and usd_limit, only for day/month and user/agent/project scopes.
  • Documented that a global budget rule never fires because _measure_budget returns None.
  • Added shared/utils/trigger_runner.py and shared/utils/dashboard/dashboard_server.py to covers: in frontmatter.
  • Removed status: migrated.
  • Ran python3 scripts/gen_docs.py --check (passes with 0 errors).

@antiv
antiv merged commit c155ffa into antiv:main Oct 11, 2026
2 checks passed
@antiv

antiv commented Oct 11, 2026

Copy link
Copy Markdown
Owner

Thanks, merged. I resolved the conflict in docs/dev/alerts.md myself this time. For the other PRs, please rebase on current main (or merge it in) instead of copying newer text onto the old branch; #219 conflicts for the same reason.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants