Regression of #533
Error message is now:
$ apollo schema:download --endpoint ... schema.json
โ Loading Apollo config
โ Fetching current schema
โ Saving schema to schema.json
โ Expected undefined to be a GraphQL schema.
Error: Expected undefined to be a GraphQL schema.
previously it was:
$ apollo schema:download --endpoint ... schema.json
โ Loading Apollo config
โ Fetching current schema
โ Response not successful: Received status code 400
Saving schema to schema.json
Error: Response not successful: Received status code 400
Is it now unclear why the command failed.
I want to upgrade from CLI 1.6 to 1.9.1, but this error i stopping me. How do I fix it?
"codegen": "yarn introspect-engine && yarn types",
"introspect-engine": "npx apollo schema:download schema.json",
"types": "npx apollo codegen:generate --target=typescript --clientSchema=src/localState/clientSchema.graphql --queries=\"src/**/*.{ts,tsx}\" --schema=schema.json --addTypename",
Running yarn codegen gives the following output, but works fine on 1.6:
yarn run v1.9.4
$ yarn introspect-engine && yarn types
$ npx apollo schema:download schema.json
โ Loading Apollo config
โ Fetching current schema
โ Saving schema to schema.json
โ Expected undefined to be a GraphQL schema.
Error: Expected undefined to be a GraphQL schema.
The update didn't fix this for me. With Apollo 1.9.2 I get the same error. Also a pity that the error isn't more descriptive..
Most helpful comment
I want to upgrade from CLI 1.6 to 1.9.1, but this error i stopping me. How do I fix it?
Running
yarn codegengives the following output, but works fine on1.6: