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
Why I would do such thing you might ask? Well ... there is no way in yarn to force version/location override of dependencies of a dependency. I tried a lot of things including the dependencies override in the package.json file without any luck. Something like that can easily be done in npm shrinwrap, just drop in a npm-shirnwrap.json file and we are good to go:
So in absense of some simmilar capability in yarn, this is the dirty hack that should work.
If the current behavior is a bug, please provide the steps to reproduce.
Yarn fails with the below error message, despite there being a package.json in the dependency package and the dependency of the dependency package.
error Couldn't find a package.json file in "C:\\Users\\fred\\workspaces\\yarn-fail\\node_modules\\keycloak-connect\\node_modules\\keycloak-auth-utils"
Example package.json to demonstrate error:
{
"name": "yarn-fail",
"version": "1.0.0",
"description": "Example package from github tarball with a nested dependency from github tarball",
"author": "Niels Bertram <nielsbne@gmail.com>",
"license": "Apache-2.0",
"dependencies": {
"keycloak-connect": "https://github.com/bertramn/keycloak-nodejs-connect/tarball/3.0.x"
}
}
Running this simple example will result in following error:
C:\Users\fred\workspaces\yarn-fail>yarn install
yarn install v0.22.0
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
error Couldn't find a package.json file in "C:\\Users\\fred\\workspaces\\yarn-fail\\node_modules\\keycloak-connect\\node_modules\\keycloak-auth-utils"
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
What is the expected behavior?
Yarn installs the package and its dependencies as per package.json declaration.
Please mention your node.js, yarn and operating system version.
windows 7 x64
node v6.10.1
yarn 0.22.0
The text was updated successfully, but these errors were encountered:
@blikblum unfortunately the workaround does not work in my case. I am using the standard GitHub source download API to pull down the package. Changing the way the sources are zipped is solely controlled by that API.
Bug
What is the current behavior?
I checked in a patched node package which has a patched dependency node package. The dependency tree look like this:
Why I would do such thing you might ask? Well ... there is no way in yarn to force version/location override of dependencies of a dependency. I tried a lot of things including the dependencies override in the
package.json
file without any luck. Something like that can easily be done in npm shrinwrap, just drop in anpm-shirnwrap.json
file and we are good to go:So in absense of some simmilar capability in yarn, this is the dirty hack that should work.
If the current behavior is a bug, please provide the steps to reproduce.
Yarn fails with the below error message, despite there being a package.json in the dependency package and the dependency of the dependency package.
Example
package.json
to demonstrate error:Running this simple example will result in following error:
What is the expected behavior?
Yarn installs the package and its dependencies as per
package.json
declaration.Please mention your node.js, yarn and operating system version.
windows 7 x64
node v6.10.1
yarn 0.22.0
The text was updated successfully, but these errors were encountered: