Open kawazoe opened 11 months ago
If I may append to the issue.
The data of the extended interface is actually inserted into the final interface generated by the plugin rather than using the extension.
As an example a schema defined as follow:
interface A {
A: int!
}
interface B extends A {
B: string!
}
produces in the plugin:
interface A {
A: int!
}
interface B {
A: Int!
B: string!
}
So B is not longer an "A" according to the generated schema, leading to weird behaviors and very subtile bugs.
Describe the bug When an interface implements another interface, the schema produced by the plugin is missing the deeper interface declaration. This results in invalid schemas, even though other tools like Banana Cake Pop produces the correct schema.
To Reproduce Use the plugin to
Get API Schema From Endpoint
for an endpoint with the following schemaExpected behavior The schema produced by the plugin should be exactly the same and include the IFoo implementation at line 5.
Actual behavior The schema looks like this:
Version and Environment Details Operation system: macOS 13.4 IDE name and version: WebStorm 2023.2 (beta), also validated with 2023.1 (stable) Plugin version: 4.0.1
Additional context I have noticed this issue when trying to define an interface that implements Node in a HotChocolate project. BananaCakePop produces the correct schema, but the plugin doesn't.