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

Unable to run create strapi admin user #333

Open
1 task
bplasmeijer opened this issue Sep 5, 2023 · 1 comment
Open
1 task

Unable to run create strapi admin user #333

bplasmeijer opened this issue Sep 5, 2023 · 1 comment
Assignees
Labels
dependencies Pull requests that update a dependency file scope: setup Taks relative to project setup

Comments

@bplasmeijer
Copy link

Are you accessing the project from the GitHub Codespaces?

  • [ X] No, I am running the project on my local machine (I will fill in the OS section below)
  • Yes, I am using GitHub Codespaces.

Note: The project is optimized to run on Codespaces. We welcome contributions to enhance it for cross-platform local development, but it's not something we will prioritize right now. Thank you!

Describe the bug
Unable to create strapi admin user, and unavailable on the current set-up.
Run blog-cms not inside the npm workspace works correctly.
Deduped on the graphql package causes the error, Duplicate "graphql" modules cannot be used at the same time since different
versions may have different capabilities and behavior. The data from one
version used in the function from another could produce confusing and
spurious results.

To Reproduce
Steps to reproduce the behavior:

docker compose up postgres postgres postgres_setup -d
npm run clean:installl
npm run strapi admin:create -w blog-cms
 npm run strapi admin:create -w blog-cms

> blog-cms@0.1.0 strapi
> strapi admin:create

? Admin email? x@y.x
? Admin password? [hidden]
? First name? x
? Last name? y
? Do you really want to create a new admin? Yes
Starting the compilation for TypeScript files in /home/bap/src/contoso-real-estate/packages/blog-cms
Error: Cannot use GraphQLScalarType "Time" from another module or realm.

Ensure that there is only one instance of "graphql" in the node_modules
directory. If different versions of "graphql" are the dependencies of other
relied on modules, use "resolutions" to ensure only one version is installed.

https://yarnpkg.com/en/docs/selective-version-resolutions

Duplicate "graphql" modules cannot be used at the same time since different
versions may have different capabilities and behavior. The data from one
version used in the function from another could produce confusing and
spurious results.
    at instanceOf (/home/bap/src/contoso-real-estate/node_modules/graphql/jsutils/instanceOf.js:43:19)
    at isScalarType (/home/bap/src/contoso-real-estate/node_modules/graphql/type/definition.js:117:37)
    at isNamedType (/home/bap/src/contoso-real-estate/node_modules/graphql/type/definition.js:464:5)
    at SchemaBuilder.addTypes (/home/bap/src/contoso-real-estate/node_modules/nexus/dist/builder.js:270:39)
    at /home/bap/src/contoso-real-estate/node_modules/nexus/dist/builder.js:281:54
    at Array.forEach (<anonymous>)
    at SchemaBuilder.addTypes (/home/bap/src/contoso-real-estate/node_modules/nexus/dist/builder.js:281:32)
    at /home/bap/src/contoso-real-estate/node_modules/nexus/dist/builder.js:278:45
    at Array.forEach (<anonymous>)
    at SchemaBuilder.addTypes (/home/bap/src/contoso-real-estate/node_modules/nexus/dist/builder.js:278:19)
npm ERR! Lifecycle script `strapi` failed with error:
npm ERR! Error: command failed
npm ERR!   in workspace: blog-cms@0.1.0
npm ERR!   at location: /home/bap/src/contoso-real-estate/packages/blog-cms

Expected behavior
image

Screenshots
If applicable, add screenshots to help explain your problem.

OS (please complete the following information):

  • OS: Windows
  • OS Version: 11
  • npm version: 9.5.0
  • Node.js version: v18.15.0
  • output of azd version:

Additional context
Add any other context about the problem here.

@anfibiacreativa anfibiacreativa added scope: setup Taks relative to project setup dependencies Pull requests that update a dependency file and removed status: needs triage labels Sep 5, 2023
@anfibiacreativa
Copy link
Member

Great analysis, Bart. Thank you and looking forward to your contribution!

bplasmeijer added a commit to bplasmeijer/contoso-real-estate that referenced this issue Sep 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file scope: setup Taks relative to project setup
Projects
None yet
Development

No branches or pull requests

2 participants