-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Description
If the GraphQL::Schema::Visibility plugin is "used" with preload: true prior to configuring the schema's root types, an exception will be raised.
NoMethodError: undefined method 'kind' for nil
gems/graphql-2.5.14/lib/graphql/schema/visibility/profile.rb:177:in 'GraphQL::Schema::Visibility::Profile#field'
gems/graphql-2.5.14/lib/graphql/schema/visibility/profile.rb:332:in 'block in GraphQL::Schema::Visibility::Profile#preload'
gems/graphql-2.5.14/lib/graphql/schema/visibility/profile.rb:328:in 'Array#each'
gems/graphql-2.5.14/lib/graphql/schema/visibility/profile.rb:328:in 'GraphQL::Schema::Visibility::Profile#preload'
gems/graphql-2.5.14/lib/graphql/schema/visibility.rb:99:in 'block in GraphQL::Schema::Visibility#preload'
gems/graphql-2.5.14/lib/graphql/schema/visibility.rb:97:in 'Hash#each'
gems/graphql-2.5.14/lib/graphql/schema/visibility.rb:97:in 'GraphQL::Schema::Visibility#preload'
gems/graphql-2.5.14/lib/graphql/schema/visibility.rb:44:in 'GraphQL::Schema::Visibility#initialize'
gems/graphql-2.5.14/lib/graphql/schema/visibility.rb:20:in 'Class#new'
gems/graphql-2.5.14/lib/graphql/schema/visibility.rb:20:in 'GraphQL::Schema::Visibility.use'
gems/graphql-2.5.14/lib/graphql/schema.rb:322:in 'GraphQL::Schema.use'
This is likely a programmer error, however a sanity check with proper error message might be more helpful. It is not immediately obvious that certain plugins need to be configured in a certain order.
Metadata
Metadata
Assignees
Labels
No labels