We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
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
With an input to a mutation like the following, neither of the inputs are optional, you must specify both:
@strawberry.input class UserUpdateInput: name: str = strawberry.UNSET description: str = strawberry.UNSET
We get an error like ""Field 'UpdateInput.name' of required type 'String!' was not provided."
If I set them to any other default value then they do become optional, as expected.
I am also trying to avoid setting the name to have a None value as this conflicts with my database setup (a non-nullable value)
Perhaps I am missunderstanding the way this should be working....
The text was updated successfully, but these errors were encountered:
@akademy that's the expected behaviour, we have a PR to make this better #3791 :D
In your case I guess you have to use None for the time being I think 😊
None
Sorry, something went wrong.
OK. Good to know!
No branches or pull requests
Describe the Bug
With an input to a mutation like the following, neither of the inputs are optional, you must specify both:
We get an error like ""Field 'UpdateInput.name' of required type 'String!' was not provided."
If I set them to any other default value then they do become optional, as expected.
System Information
Additional Context
I am also trying to avoid setting the name to have a None value as this conflicts with my database setup (a non-nullable value)
Perhaps I am missunderstanding the way this should be working....
The text was updated successfully, but these errors were encountered: