Events: per-project rules with severities and five delivery channels #12
No reviewers
Labels
No labels
breaking
bug
ci
dependencies
documentation
feature
security
skip-changelog
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
argus/backend!12
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/10-events"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #10
Backend part of the multi-channel events feature. The UI comes in an argus/frontend PR, the upload metadata in an argus/upload-action PR.
What's in it
apps.eventsappEventRule: trigger + params, severity, ref/type filters, channels, recipients, extra emails.EventRuleStatekeeps one row per rule, ref, type and variant, for de-duplication.Event,EventDelivery,UserNotification,PushSubscription,PrComment.status_fail,status_warn,regressionandrecoveryare evaluated afterrecompute_aggregate, with all variants combined.coverage_below,coverage_drop(vs. the previous report or a baseline branch),failed_tests_above,processing_errorandnew_reportare evaluated afterprocess_report.failed. A channel that doesn't apply isskippedwith a reason.pywebpush, VAPID). Expired subscriptions (404/410) are dropped.<!-- argus-event:{rule_id} -->).projects/<o>/<r>/event-rules/: CRUD needs write;follow/needs read;test/sends a sample on desktop/email/Mattermost and records nothing.event-rules/recipients/: user picker.projects/<o>/<r>/events/andevents/: summary lists, filterable by severity, trigger, rule, ref, type, delivery state (incl.none) and period, paginated.me/notifications/andme/notifications/read/.push/config/andpush/subscriptions/.mattermost/channels/.Report.run_urlandReport.actor, both optional upload fields, used in event messages.argusMattermostBotToken,argusVapidPrivateKey) on web and worker.deploy/README.md§ 6.Before merging
/srv/docker/argus/secrets/; an empty file disables that channel. Docker refuses to start with a missing secret.write:issuefor PR comments (already done).Not included
new_reportevent.Tests
34 new pytest cases (169 in total): every trigger, de-duplication, each channel mocked, retries, permissions, API filters, upload metadata.
coversmarkers are added tofeatures.catalog.yaml. pylint 10/10, autopep8 and bandit clean.🤖 Generated with Claude Code
https://claude.ai/code/session_014BSmBtGWeFBD9z4mYm9SjA
📊 Rapports Argus pour cette PR