-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DeviceType_Count on Manufacturer #17976
Comments
The While it's feasible to fix this by explicitly attaching the annotation to DeviceTypeViewSet, we should instead extend the dynamic logic to account for nested fields, as it's very likely there are similar instances in other nested serializers that also need to be addressed. |
@ZionDials just realized that you volunteered for this. Assigning to you, thanks! |
@ZionDials are you still planning to work on this? |
I've made several efforts to analyze the situation and identify a solution; however, I realize that I don't have the necessary expertise to resolve this issue effectively. |
Updated
might need to add the annotation directly on the prefetch, along the lines of:
|
Deployment Type
Self-hosted
Triage priority
I volunteer to perform this work (if approved)
NetBox Version
v4.1.6
Python Version
3.10
Steps to Reproduce
GET /api/dcim/device-types/
Note
"devicetype_count"
is missing.Expected Behavior
The expected response, according to the OpenAPI specification for Netbox:
GET /api/dcim/device-types/
Observed Behavior
According to the OpenAPI specification BriefManufacturer has a required field of
"devicetype_count"
. However, when querying DeviceTypes and ModuleTypes, the field is not populated and causes SDKs using the OpenAPI generator, to fail.Go-Netbox Creating Manufacture errors out because of missing required property devicetype_count #165
The text was updated successfully, but these errors were encountered: