You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Client Framework and version (Relay, Apollo, etc): N/A getting compilation error
Expected behavior
The schema compiles and the implementing sub-type is valid.
Actual behavior
Compilation error
Type "header_cell" does not fully implement interface type "manifest_cell" for fields [:text]
...
* An object field type is a valid sub-type if it is a Non-Null variant of a
valid sub-type of the interface field type.
Relevant Schema/Middleware Code
interface :manifest_cell do
field :text, :string
end
object :header_cell do
field :text, non_null(:string)
interface :manifest_cell
is_type_of &is_struct(&1, HeaderCell)
end
The text was updated successfully, but these errors were encountered:
Fixesabsinthe-graphql#987
Two cases are added to the schema:
* a simple nullable interface -> non-nullable implementor.
* a nullable list -> with implementors `list_of(non_null(type))` and
`non_null(list_of(non_null(type)))`.
From my reading of the spec these should all validate.
https://spec.graphql.org/draft/#IsValidImplementationFieldType()
I did find that it is not validated whether the object implements
the field's arguments. Also that the object does not implement
extra non-nullable arguments that are not specified in the interface,
this is not allowed. I'll create an issue for this.
Environment
Expected behavior
The schema compiles and the implementing sub-type is valid.
Actual behavior
Compilation error
Relevant Schema/Middleware Code
The text was updated successfully, but these errors were encountered: