You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When specifying a Git dependency in package.json, PNPM unexpectedly installs the master branch instead of the explicitly declared empty branch. This behavior contrasts with Yarn, which accurately installs the specified empty branch for the react-native-camera-kit dependency. This inconsistency in PNPM's interpretation of Git URLs compared to Yarn can lead to potential confusion and errors in dependency management.
Understanding the Issue
The package.json declaration for installing a Git dependency is as follows:
This line instructs the package manager to clone the react-native-camera-kit repository from the specified GitLab URL, specifically targeting the empty branch. While Yarn follows this directive accurately, PNPM diverges by defaulting to the repository's main branch (commonly master), ignoring the branch specifier in the URL.
Expected Behavior
Installing the Exact Version of a Dependency
Which Node.js version are you using?
14.21.3
Which operating systems have you used?
macOS
Windows
Linux
If your OS is a Linux based, which one it is? (Include the version if relevant)
No response
The text was updated successfully, but these errors were encountered:
Verify latest release
pnpm version
8.15.1
Which area(s) of pnpm are affected? (leave empty if unsure)
Dependencies resolver, CLI
Link to the code that reproduces this issue or a replay of the bug
https://github.com/datrhi/pnpm-git-resolve-bug
Reproduction steps
Describe the Bug
PNPM Git Resolver Issue: Incorrect Branch Installation
When specifying a Git dependency in
package.json
, PNPM unexpectedly installs themaster
branch instead of the explicitly declaredempty
branch. This behavior contrasts with Yarn, which accurately installs the specifiedempty
branch for thereact-native-camera-kit
dependency. This inconsistency in PNPM's interpretation of Git URLs compared to Yarn can lead to potential confusion and errors in dependency management.Understanding the Issue
The
package.json
declaration for installing a Git dependency is as follows:This line instructs the package manager to clone the react-native-camera-kit repository from the specified GitLab URL, specifically targeting the empty branch. While Yarn follows this directive accurately, PNPM diverges by defaulting to the repository's main branch (commonly master), ignoring the branch specifier in the URL.
Expected Behavior
Installing the Exact Version of a Dependency
Which Node.js version are you using?
14.21.3
Which operating systems have you used?
If your OS is a Linux based, which one it is? (Include the version if relevant)
No response
The text was updated successfully, but these errors were encountered: