Skip to content

Deleting a "Notification Group" causes Server Error "NotificationGroup matching query does not exist" in the Event Rule edit view #19702

Closed
@joernheissler

Description

@joernheissler

Deployment Type

Self-hosted

NetBox Version

v4.3.2

Python Version

3.11

Steps to Reproduce

  1. Navigate to Operations/Notification Groups
  2. Add a new notification group:
    • Name "foo"
    • select your user as target
    • (details probably don't matter here)
  3. Navigate to Operations/Event Rules
  4. Add a new event rule:
    • Name "bar"
    • Object types: Circuits > Circuit
    • Event types: Object created
    • Action type: Notification
    • Notification group: foo
  5. Navigate to Operations/Notification Groups
  6. Delete the "foo" group. Confirm the deletion.
  7. Navigate to Operations/Event Rules
  8. Click the small "edit" button of the "bar" event rule.

Expected Behavior

When deleting the notification group, I expect NetBox to ask me about deleting the event rule(s) which use this notification group. When deleting a referenced web hook, NetBox does ask about deleting the event rules.

I expected NetBox to not show me a "Server Error" (see "Observed Behavior").

Observed Behavior

When I delete the event group (step 6) netbox:

Delete notification group?

Confirm Deletion

Are you sure you want to delete foo?

[Cancel] [Delete]

When visiting https://netbox-stg.example.net/extras/event-rules/4/edit/?return_url=/extras/event-rules/ (step 8) I get:

Server Error

There was a problem with your request. Please contact an administrator.

The complete exception is provided below:

<class 'extras.models.notifications.NotificationGroup.DoesNotExist'>

NotificationGroup matching query does not exist.

Python version: 3.11.2
NetBox version: 4.3.2
Plugins:
netbox_reorder_rack: 1.1.3

If further assistance is required, please post to the NetBox discussion forum on GitHub.

The broken event rule can be deleted, so no manual edits of the database are required.

Activity

added
type: bugA confirmed report of unexpected behavior in the application
status: needs triageThis issue is awaiting triage by a maintainer
on Jun 13, 2025
changed the title [-]Deleting a "Notification Group" causes "" error in the Event Rule view[/-] [+]Deleting a "Notification Group" causes Server Error "NotificationGroup matching query does not exist" in the Event Rule view[/+] on Jun 13, 2025
changed the title [-]Deleting a "Notification Group" causes Server Error "NotificationGroup matching query does not exist" in the Event Rule view[/-] [+]Deleting a "Notification Group" causes Server Error "NotificationGroup matching query does not exist" in the Event Rule edit view[/+] on Jun 13, 2025
added
status: needs ownerThis issue is tentatively accepted pending a volunteer committed to its implementation
severity: lowDoes not significantly disrupt application functionality, or a workaround is available
and removed
status: needs triageThis issue is awaiting triage by a maintainer
on Jun 13, 2025
jnovinger

jnovinger commented on Jun 13, 2025

@jnovinger
Member

Thanks for the detailed report, @joernheissler !

self-assigned this
on Jun 16, 2025
added
status: acceptedThis issue has been accepted for implementation
and removed
status: needs ownerThis issue is tentatively accepted pending a volunteer committed to its implementation
on Jun 16, 2025
added a commit that references this issue on Jun 16, 2025

Fixes #19702: add NotificationGroup.event_rules GenericRelation

210237b
added this to the v4.3.3 milestone on Jun 16, 2025
added a commit that references this issue on Jun 19, 2025

Fixes #19702: add NotificationGroup.event_rules GenericRelation

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

Metadata

Metadata

Assignees

Labels

severity: lowDoes not significantly disrupt application functionality, or a workaround is availablestatus: acceptedThis issue has been accepted for implementationtopic: event rulesFor issues related to the Event Rules featuretype: bugA confirmed report of unexpected behavior in the application

Type

Projects

No projects

Relationships

None yet

    Participants

    @jnovinger@joernheissler

    Issue actions

      Deleting a "Notification Group" causes Server Error "NotificationGroup matching query does not exist" in the Event Rule edit view · Issue #19702 · netbox-community/netbox