-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Add Enum support for directives #1706
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
Add Enum support for directives #1706
Conversation
|
We are going to decline this directive. The code path changed is in fact invalid in and of itself. That is in the absence of a directive definition, this code base tries to guess a value. But this is wrong. Which is why enum and object type are not supported. We have no way of guessing. The real fix is that we enforce "having to declare schema directives". That is if you declare |
|
@bbakerman thanks for the answer. Could you clarify will |
|
@AnkBurov yes this is how we will support enums (and everything else): you have to declare the directive. |
|
@andimarek Any specific plans about supporting enums in directive arguments? Because the following schema currently is unsupported in |
|
@AnkBurov this example you mentioned is working: See this comment #1500 (comment) |
|
Yes, I can confirm that this is working. The problem was that the project
|
|
@AnkBurov how did you work around this issue? I'm currently facing the same problem and I'm not seeing a way to overcome this without ditching graphql-java-tools at this point, which really isn't possible in my project. |
|
@etheran I'm using a fork of the project with this merged pull request AnkBurov@d5429d5 Other solutions are related with rewriting If you face the same issue (which you do) I suggest you to make a fork with similar changes and use it everywhere where you need a combination of Or you can try to persuade |
|
@AnkBurov @etheran the original reported issue is fixed: GraphQL Java supports Enums as directive arguments. The original exception also doesn't exist anymore (the whole code sections is changed). If there is another Issue or something similar please open a new Issue and describe what the problem is. |
#1500
Currently enum types in directives are not supported for some reason. A PR to add support for them.