Steps to repro wundergraph/cosmo#1440
npm i
npm run dev:subgraphs
npx wgc router compose -i cosmo-compose-broken.yaml -o cosmo-router.json
docker run -it --rm --volume ./cosmo-router.json:/router.json --volume ./cosmo-config.yaml:/config.yaml --network host -e LISTEN_ADDR=0.0.0.0:3003 ghcr.io/wundergraph/cosmo/router:0.151.1
npm i
npm run dev:subgraphs
npx wgc router compose -i cosmo-compose-works.yaml -o cosmo-router.json
docker run -it --rm --volume ./cosmo-router.json:/router.json --volume ./cosmo-config.yaml:/config.yaml --network host -e LISTEN_ADDR=0.0.0.0:3003 ghcr.io/wundergraph/cosmo/router:0.151.1
The query below will cause the router to crash:
query {
a {
id
fieldFromA
... on A1 {
fieldFromA1
fieldFromB
}
... on A2 {
fieldFromA2
}
}
b {
id
fieldFromB
}
c {
id
fieldFromC
a {
id
... on A1 {
fieldFromA1
}
}
}
}