Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

graphql-transformer-core requires amplify-cli-core but is not a dependency #6123

Closed
kcwinner opened this issue Dec 9, 2020 · 2 comments · Fixed by #6124
Closed

graphql-transformer-core requires amplify-cli-core but is not a dependency #6123

kcwinner opened this issue Dec 9, 2020 · 2 comments · Fixed by #6124
Assignees
Labels
bug Something isn't working platform Issues tied to the general CLI platform

Comments

@kcwinner
Copy link

kcwinner commented Dec 9, 2020

Note: If your issue/bug is regarding the AWS Amplify Console service, please log it in the
Amplify Console GitHub Issue Tracker

Describe the bug
graphql-transformer-core/src/util/sanity-check.ts requires amplify-cli-core but amplify-cli-core is not listed as a dependency in package.json as of version 6.24.0 (6.23.1 was last working version for me).

I received the following error when attempting to upgrade from 6.23.1 to 6.25.0:

cdk-appsync-transformer % yarn test
yarn run v1.22.10
$ rm -fr lib/ && jest --passWithNoTests --updateSnapshot
 FAIL  test/index.test.ts
  ● Test suite failed to run

    Cannot find module 'amplify-cli-core' from 'node_modules/graphql-function-transformer/node_modules/graphql-transformer-core/lib/util/sanity-check.js'

Amplify CLI Version
N/A - using amplify graphql-transformer libraries outside of amplify-cli

To Reproduce

git clone -b repro/graphql-transformer-dependencies https://github.com/kcwinner/cdk-appsync-transformer.git
npx projen
yarn test

Expected behavior
graphql-transformer libraries working without the global context of amplify-cli

Screenshots
Screen Shot 2020-12-09 at 9 39 50 AM

Desktop (please complete the following information):

  • OS: Mac
  • Node Version: v12.17.0

Additional context
I use the graphql-transformer libraries in a cdk construct to allow directive based schema usage.

@attilah attilah added bug Something isn't working platform Issues tied to the general CLI platform labels Dec 9, 2020
@attilah attilah self-assigned this Dec 9, 2020
@attilah
Copy link
Contributor

attilah commented Dec 10, 2020

@kcwinner thanks for the heads up I created the PR after double checking for other packages.

@github-actions
Copy link

This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs.

Looking for a help forum? We recommend joining the Amplify Community Discord server *-help channels for those types of questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 25, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working platform Issues tied to the general CLI platform
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants