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

Getting "This should never happen" error on incorrect fragment name #189

Open
jeggy opened this issue Jun 9, 2022 · 0 comments
Open

Getting "This should never happen" error on incorrect fragment name #189

jeggy opened this issue Jun 9, 2022 · 0 comments

Comments

@jeggy
Copy link
Member

jeggy commented Jun 9, 2022

When having a GraphQL query like this:

{
  persons {
    nodes {
      id
      ...MyFragment2
    }
  }
}

fragment MyFragment on Person {
  lastName
}

it throws an IllegalArgumentException with the message "This should never happen", coming from here:
https://github.com/aPureBase/KGraphQL/blob/main/kgraphql/src/main/kotlin/com/apurebase/kgraphql/schema/structure/RequestInterpreter.kt#L208

As seen by the query it's a simple mistake and I'm using the incorrect fragment name, so a proper error would be much appreciated.

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

No branches or pull requests

1 participant