-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Closed
Copy link
Labels
severity: lowDoes not significantly disrupt application functionality, or a workaround is availableDoes not significantly disrupt application functionality, or a workaround is availablestatus: acceptedThis issue has been accepted for implementationThis issue has been accepted for implementationtopic: GraphQLtype: bugA confirmed report of unexpected behavior in the applicationA confirmed report of unexpected behavior in the application
Milestone
Description
Deployment Type
Self-hosted
NetBox Version
v4.2.5
Python Version
3.10
Steps to Reproduce
Reproducable on demo.netbox.dev. Also on v4.2.6 in our environment
- Create a Inventory-Item on any device and leave the manufacturer blank (as it is not required
- Query the following graph-ql (with the specific device-id):
query {
device(id:172) {id name inventoryitems {id name manufacturer{id name}}}
}
Expected Behavior
Output of Device with given Inventory-Items and manufacturer to be null (i.e. like if tenant is not set):
{
"data": {
"device": {
"id": "172",
"name": "0634LEO",
"inventoryitems": [
{
"id": "1",
"name": "Test",
"manufacturer": null
}
]
}
}
}
Observed Behavior
Error raised that manufacturer cannot be null:
{
"data": null,
"errors": [
{
"message": "Cannot return null for non-nullable field InventoryItemType.manufacturer.",
"locations": [
{
"line": 2,
"column": 68
}
],
"path": [
"device",
"inventoryitems",
0,
"manufacturer"
]
}
]
}
Metadata
Metadata
Assignees
Labels
severity: lowDoes not significantly disrupt application functionality, or a workaround is availableDoes not significantly disrupt application functionality, or a workaround is availablestatus: acceptedThis issue has been accepted for implementationThis issue has been accepted for implementationtopic: GraphQLtype: bugA confirmed report of unexpected behavior in the applicationA confirmed report of unexpected behavior in the application