AxeWP / wp-graphql-gravity-forms

GraphQL API for interacting with Gravity Forms.
GNU General Public License v3.0
165 stars 29 forks source link

Uncaught TypeError: Return value of GraphQL\Type\Schema::resolveType() must be an instance of GraphQL\Type\Definition\Type, null returned #189

Closed cpramod closed 2 years ago

cpramod commented 2 years ago

Got this error with gravity form version: 2.5.15, grapql version: 1.6.7 and wp-graphql-gravity-forms plugin version 0.9.2. On deactivating wp-graphql-gravity-forms plugin, the error gets resolved.

error message: Uncaught TypeError: Return value of GraphQL\Type\Schema::resolveType() must be an instance of GraphQL\Type\Definition\Type, null returned

justlevine commented 2 years ago

Thank's for reporting, @cpramod ! Did this occur when you were trying to run a specific query? Or just by opening up WPGraphiql? What other plugins (WPGraphQL related or otherwise) do you have enabled?

Also can you enable GraphQL debugging, and provide the entire response for that error? (You should be able to to go to your browser development tools > network, find the failed GraphQL request, and then copy/paste the entire response).

Those null resolveType errors are usually easy to fix but particularly tricky to diagnose, and can be caused by a mistyped GraphQL field, a field being registered out of order, naming conflicts with other WPGraphQL extensions, or even CPTs that core picks up and generates the schema for.

justlevine commented 2 years ago

@cpramod are you still experiencing this issue?

cpramod commented 2 years ago

@justlevine It is fixed. it was due to plugin conflict. Thank you

justlevine commented 2 years ago

Glad to hear!