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
Make sure to fork this template and run yarn generate in the terminal.
Please make sure Mesh package versions under package.json matches yours.
2. A failing test has been provided
3. A local solution has been provided
4. A pull request is pending review
Describe the bug
When using loadOpenAPISubgraph from @omnigraph/openapi the common types e.g. void_container.Void are subject to the same transformations as all the other types. This causes issues when loading two subgraphs, they need to have the exact same transforms otherwise mesh-compose throws an error
> mesh-compose -o supergraph.graphql
[2024-12-31T17:37:36.982Z] INFO Mesh Compose Found default config file /Users/richardchamberlain/dev/graphql-mesh-conflict/mesh.config.ts
[2024-12-31T17:37:37.106Z] INFO Mesh Compose Loaded config
[2024-12-31T17:37:37.106Z] INFO Mesh Compose Composing
[2024-12-31T17:37:37.181Z] INFO Mesh Compose Writing schema to supergraph.graphql
[2024-12-31T17:37:37.184Z] INFO Mesh Compose Done!
Actual behaviour
> mesh-compose -o supergraph.graphql
[2024-12-31T17:39:29.941Z] INFO Mesh Compose Found default config file /Users/richardchamberlain/dev/graphql-mesh-conflict/mesh.config.ts
[2024-12-31T17:39:30.062Z] INFO Mesh Compose Loaded config
[2024-12-31T17:39:30.062Z] INFO Mesh Compose Composing
[2024-12-31T17:39:30.135Z] ERROR Mesh Compose Failed to compose subgraphs
[2024-12-31T17:39:30.135Z] ERROR Mesh Compose The following supergraph API query:
{
differentEndpoint {
... on Void_container {
Void
}
}
}
cannot be satisfied by the subgraphs because:
- from subgraph "APITwo":
- cannot find field "Void_container.Void".
- cannot move to subgraph "APIOne", which has field "Void_container.Void", because type "Void_container" has no @key defined in subgraph "APIOne".
[2024-12-31T17:39:30.135Z] ERROR Mesh Compose The following supergraph API query:
{
example {
... on Void_container {
void
}
}
}
cannot be satisfied by the subgraphs because:
- from subgraph "APIOne":
- cannot find field "Void_container.void".
- cannot move to subgraph "APITwo", which has field "Void_container.void", because type "Void_container" has no @key defined in subgraph "APITwo".
Environment:
OS: OSX
@graphql-mesh/compose-cli": "^1.3.4:
NodeJS: 22
Additional context
The text was updated successfully, but these errors were encountered:
Issue workflow progress
Progress of the issue based on the
Contributor Workflow
Github,
Stackblitz
or
CodeSandbox
Describe the bug
When using
loadOpenAPISubgraph
from@omnigraph/openapi
the common types e.g. void_container.Void are subject to the same transformations as all the other types. This causes issues when loading two subgraphs, they need to have the exact same transforms otherwisemesh-compose
throws an errorTo Reproduce Steps to reproduce the behavior:
mesh.config
schema1
schema2
Expected behavior
A successful compose
Actual behaviour
Environment:
@graphql-mesh/compose-cli": "^1.3.4
:Additional context
The text was updated successfully, but these errors were encountered: