-
Notifications
You must be signed in to change notification settings - Fork 822
Introspection isn't generating standard-compliant schema #940
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
Comments
How is #877 related? |
Please provide example of what's wrong in the schema (expected value vs. what graphene generates) |
Hi Eran. The issue is how default enum values are serialized in the introspection query response. The GitHub API has the same problem where it also deviates from the spec. Here's the bug report that I sent to them earlier:
I hope that provides enough information. I'm not familiar with python or graphene, but the schema that would reproduce this looks something like: enum Episode {
JEDI,
EMPIRE
}
type Query {
heroName(episode: Episode = JEDI): String
} The introspection result would then return a Best regards, |
Seems like this related to #756 |
@arielnmz @jimkyndemeyer so per @avivey note on issue #877 , the problem is not that graphene generates the wrong schema but that its handling of Python Enums is awkward. This should still generate a valid schema (but you have to remember to use
We have a PR in the works to better handle Enums, but as this is a breaking change its not an easy change to introduce and we're trying to figure out the best way to introduce it as a "feature flag" you'll need to explicitly turn on. Follow this PR for updates: #879 |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Related: JetBrains/js-graphql-intellij-plugin#229
Apparently, the introspection is not returning a compliant schema, breaking the before mentioned project's functionality.
Also related: #877
The text was updated successfully, but these errors were encountered: