ObjectCountsWidget can brick Netbox home page #10172

Closed
opened 2025-12-29 21:27:46 +01:00 by adam · 0 comments
Owner

Originally created by @candlerb on GitHub (Sep 3, 2024).

Originally assigned to: @candlerb on GitHub.

Deployment Type

Self-hosted

NetBox Version

v4.0.10

Python Version

3.12

Steps to Reproduce

  1. Go to home page
  2. Click on settings cog next to an Object Counts widget
  3. Add "DCIM > Console Server Port Template" to the list of objects to count, and click Save

image

Expected Behavior

Netbox continues to function, or the change is rejected.

Observed Behavior

Netbox web UI crashes and is unusable. There is no way to recover from the web UI.

image

This is because there is a hard-coded assumption in the widget that all models have a foo_list endpoint, but template components don't.

Originally raised in discussion #17336

Originally created by @candlerb on GitHub (Sep 3, 2024). Originally assigned to: @candlerb on GitHub. ### Deployment Type Self-hosted ### NetBox Version v4.0.10 ### Python Version 3.12 ### Steps to Reproduce 1. Go to home page 2. Click on settings cog next to an Object Counts widget 3. Add "DCIM > Console Server Port Template" to the list of objects to count, and click Save ![image](https://github.com/user-attachments/assets/b50d066d-4adb-478f-8154-c0c574c06a5e) ### Expected Behavior Netbox continues to function, or the change is rejected. ### Observed Behavior Netbox web UI crashes and is unusable. There is no way to recover from the web UI. ![image](https://github.com/user-attachments/assets/bcf8ad3e-8d71-434c-89bf-7b3ce3718b7e) This is because there is a hard-coded assumption in the widget that all models have a `foo_list` endpoint, but template components don't. Originally raised in discussion #17336
adam added the type: bugstatus: acceptedseverity: medium labels 2025-12-29 21:27:46 +01:00
adam closed this issue 2025-12-29 21:27:47 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#10172