-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Closed
Labels
k/bugSomething isn't workingSomething isn't working
Description
Version Information
Server Version: v2.48.1-cloud.1
CLI Version (for CLI related issue):
Environment
Cloud
What is the current behaviour?
When trying to give provide role based access to a remote schema.
validation for the given role-based schema failed because expected default value of input value: "isActive" of input object "CreateCategoryInput" to be true but received "true"
Looking at the graphql schema, the Boolean is typed correctly.
input CreateCategoryInput {
isActive: Boolean = true
}
Introspecting the schema, shows that the type is Boolean, but it's possible that Hasura is being tripped up by the defaultValue is encoded as "true"
{
"data": {
"__type": {
"name": "CreateCategoryInput",
"kind": "INPUT_OBJECT",
"inputFields": [
{
"name": "isActive",
"defaultValue": "true",
"type": {
"kind": "SCALAR",
"name": "Boolean",
"ofType": null
}
}
]
}
}
}
What is the expected behaviour?
I should be able to set role permission on a remote schema with a default Boolean value
How to reproduce the issue?
- Create a schema with a default Boolean input.
Screenshots or Screencast
Please provide any traces or logs that could help here.
Any possible solutions/workarounds you're aware of?
Do not set a default value in GraphQL
Keywords
remote-schema, role-based, default-value
HaiNNT
Metadata
Metadata
Assignees
Labels
k/bugSomething isn't workingSomething isn't working