You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On a filter input type set the filter for a field to .Type<IdOperationFilterInputType>() to make the filter use ID for the field instead of something like Int. Then try to query it.
{
books(where: {
id: {
eq: 1
}
}) {
nodes {
id
title
}
}
}
Response
{
"errors": [
{
"message": "The node ID string has an invalid format.",
"locations": [
{
"line": 2,
"column": 3
}
],
"path": [
"books"
],
"extensions": {
"originalValue": "1"
}
}
],
"data": {
"books": null
}
}
What is expected?
Expect the filtering to work and convert the ID to the underlying type, just like if you set an attribute to use IdType.
What is actually happening?
Instead I get the above error.
Relevant log output
Additional context
Using id: { eq: "1"} with the ID as a string makes no difference.
The text was updated successfully, but these errors were encountered:
Product
Hot Chocolate
Version
14.3.0
Link to minimal reproduction
https://github.com/dalen/hotchocolate-reproduction/tree/main/HotChocolateIdFilter
Steps to reproduce
On a filter input type set the filter for a field to
.Type<IdOperationFilterInputType>()
to make the filter use ID for the field instead of something likeInt
. Then try to query it.Response
What is expected?
Expect the filtering to work and convert the ID to the underlying type, just like if you set an attribute to use
IdType
.What is actually happening?
Instead I get the above error.
Relevant log output
Additional context
Using
id: { eq: "1"}
with the ID as a string makes no difference.The text was updated successfully, but these errors were encountered: