Skip to content
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

support input object fields #13

Merged
merged 11 commits into from
Feb 15, 2023
Merged

support input object fields #13

merged 11 commits into from
Feb 15, 2023

Conversation

rperryng
Copy link
Owner

@rperryng rperryng commented Feb 7, 2023

fixes #12

What changed

  • inspect node.value during on_enter_argument
    • if its a variable, add all values (all fields if an input object or all possibilities of an enum) as used
    • if its a list, iterate and add the values / fields of input objects
    • if its an explicit value, iterate through the given values and mark the input object fields, or given enum value, as used

@rperryng
Copy link
Owner Author

rperryng commented Feb 7, 2023

Hmm I realized this doesn't yet handle list values.

@rperryng rperryng changed the title support explicit input object fields [do not merge] support explicit input object fields Feb 7, 2023
@rperryng
Copy link
Owner Author

rperryng commented Feb 7, 2023

Okay! Lists of enums / input objects are now supported.

Though now I also realize that hardcoded null values in arguments/lists would probably break things (though I think that was the case before too) - I would be happy to tackle this in another PR if there's a want for it

@rperryng rperryng changed the title [do not merge] support explicit input object fields support explicit input object fields Feb 8, 2023
@rperryng rperryng changed the title support explicit input object fields support input object fields Feb 8, 2023
@rperryng rperryng merged commit 5bc60f8 into rperryng:master Feb 15, 2023
@rperryng rperryng mentioned this pull request Feb 15, 2023
@rperryng rperryng deleted the collect-used-arguments branch February 15, 2023 22:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

input object fields break usage collection
1 participant