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

Fix skip/include directives on fragment spreads #200

Merged
merged 1 commit into from
Feb 24, 2021

Conversation

dwwoelfel
Copy link
Contributor

Quick patch for skip/include directives on fragment spreads.

The directives weren't being applied to the fragment spread because it was looking at the directives that were defined on the fragment definition (where skip and include aren't allowed).

In the example below, it was looking at (the made-up) fragmentDefDirective instead of the skip directive.

query TestQuery {
  test {
    ...TestFragment @skip(if: true)    
  }
}

fragment TestFragment on Test @fragmentDefDirective {
  id
}

Includes a test.

Copy link
Contributor

@anmonteiro anmonteiro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this!

@andreas andreas merged commit 4f12d93 into andreas:master Feb 24, 2021
@andreas
Copy link
Owner

andreas commented Feb 24, 2021

Thanks @dwwoelfel!

kit-ty-kate pushed a commit to ocaml/opam-repository that referenced this pull request Jul 19, 2022
…d graphql-async (0.14.0)

CHANGES:

- Support `__typename` on subscriptions (andreas/ocaml-graphql-server#178)
- Handle unknown fields for subscriptions (andreas/ocaml-graphql-server#178)
- Add ocamlformat (andreas/ocaml-graphql-server#177)
- Handle missing variables as null (andreas/ocaml-graphql-server#184)
- Show default value in introspection query (andreas/ocaml-graphql-server#194)
- Support block strings in the parser (andreas/ocaml-graphql-server#198)
- Handle skip/include directives on fragment spreads (andreas/ocaml-graphql-server#200)
- Improved handling of recursive arguments and objects (andreas/ocaml-graphql-server#199)
- Fix websocket conflict (andreas/ocaml-graphql-server#206)
- Update deprecated Fmt functions (andreas/ocaml-graphql-server#206)
- Use Yojson `t` types instead of deprecated `json` type (andreas/ocaml-graphql-server#208)
- Raise minimum `rresult` version (andreas/ocaml-graphql-server#209)
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.

3 participants