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

[Bug?]: Yarn 4 cannot install the packages from github #6240

Open
1 task
DharanBro opened this issue Apr 19, 2024 · 1 comment
Open
1 task

[Bug?]: Yarn 4 cannot install the packages from github #6240

DharanBro opened this issue Apr 19, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@DharanBro
Copy link

DharanBro commented Apr 19, 2024

Self-service

  • I'd be willing to implement a fix

Describe the bug

Adding the package from github url fails with

➤ YN0000: · Yarn 4.1.1
➤ YN0000: ┌ Resolution step
➤ YN0058: │ google-map-react@https://github.com/google-map-react/google-map-react.git#commit=6fe7e11c4f9e2519097eb59f039681ee573efb8f: Packing the package failed (exit code 1, logs can be found here: /private/var/folders/m7/x__rb0q55rq0y56m5klj7j000000gn/T/xfs-d422264e/pack.log)
➤ YN0000: └ Completed in 54s 114ms
➤ YN0000: · Failed with errors in 54s 123ms

pack.log

Packing google-map-react@https://github.com/google-map-react/google-map-react.git#commit=6fe7e11c4f9e2519097eb59f039681ee573efb8f from sources
Using Yarn Classic for bootstrap. Reason: "__metadata" key not found in yarn.lock, must be a Yarn classic lockfile

➤ YN0000: Downloading https://classic.yarnpkg.com/latest.js
➤ YN0000: Saving the new release in .yarn/releases/yarn-classic.cjs
➤ YN0000: Done in 4s 855ms

yarn install v1.22.19
[1/5] Validating package.json...
[2/5] Resolving packages...
[3/5] Fetching packages...
[4/5] Linking dependencies...
warning "react-scripts > @typescript-eslint/eslint-plugin > tsutils@3.21.0" has unmet peer dependency "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta".
[5/5] Building fresh packages...
$ run-s build
�[31m�[1mInternal Error�[22m�[39m: google-map-react@workspace:.: This package doesn't seem to be present in your lockfile; run "yarn install" to update the lockfile
    at Xx.getCandidates (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:205:8149)
    at Dd.getCandidates (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:141:1311)
    at /Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:210:8409
    at Ky (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:140:53916)
    at Fe (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:210:8389)
    at async Promise.allSettled (index 0)
    at async Uc (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:140:53244)
    at async /Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:210:9140
    at async Qi.startProgressPromise (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:140:137284)
    at async Pt.resolveEverything (/Users/user/.volta/tools/image/yarn/4.1.1/bin/yarn.js:210:7138)
ERROR: "build" exited with 1.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

To reproduce

run yarn add google-map-react@https://github.com/google-map-react/google-map-react

Environment

System:
    OS: macOS 13.5.2
    CPU: (10) arm64 Apple M1 Pro
  Binaries:
    Node: 20.12.0 - /private/var/folders/m7/x__rb0q55rq0y56m5klj7j000000gn/T/xfs-c3858d0f/node
    Yarn: 4.1.1 - /private/var/folders/m7/x__rb0q55rq0y56m5klj7j000000gn/T/xfs-c3858d0f/yarn
    npm: 10.5.0 - ~/.volta/tools/image/node/20.12.0/bin/npm

Additional context

No response

@DharanBro DharanBro added the bug Something isn't working label Apr 19, 2024
@zach-betz-hln
Copy link

Your yarn version seems to be Yarn 4.1.1 but v1.22.19 is used to install this package per your log output.

Looks like the cause is:

Packing google-map-react@https://github.com/google-map-react/google-map-react.git#commit=6fe7e11c4f9e2519097eb59f039681ee573efb8f from sources
Using Yarn Classic for bootstrap. Reason: "__metadata" key not found in yarn.lock, must be a Yarn classic lockfile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants