Open Hebilicious opened 1 year ago
While this issue is related to latest specifically, it looks very similar to https://github.com/oven-sh/bun/issues/4650 and https://github.com/oven-sh/bun/issues/4676
Can confirm, I'm running into the same issue.
Same
Running into the same issue as well
If you reference the dependency using the workspace protocol (e.g. "my-package": "workspace:*") it works. Notice that you have to delete the bun.lockb and run "bun install" for this to take effect. I sent a PR to fix this in the docs (https://github.com/oven-sh/bun/pull/4875).
If you reference the dependency using the workspace protocol (e.g. "my-package": "workspace:*") it works. Notice that you have to delete the bun.lockb and run "bun install" for this to take effect. I sent a PR to fix this in the docs (#4875).
Imo "workspace:*" is a workaround, things should work if you are using latest or the correct version.
@bndkt @nbbaier @virus2016 Please add a 👍🏽 to the first comment, comments like "same" are automatically hidden by GitHub.
@bndkt @nbbaier @virus2016 Please add a 👍🏽 to the first comment, comments like "same" are automatically hidden by GitHub.
Done!
@dylan-conway is this a bug or a documentation issue? if this is a documentation issue, can you update the docs?
What version of Bun is running?
1.0.0+822a00c4d508b54f650933a73ca5f4a3af9a7983
What platform is your computer?
Darwin 22.6.0 arm64 arm
What steps can reproduce the bug?
1) Create a bun workspace with the following config
workspaces: ["a", "b"]
2) Add{ dependencies: {a: latest }}
to b package.json 3) Runbun i
Even if A exists locally, bun will fetch the npm version and install it in
/b/node_modules/a
What is the expected behavior?
I would expect a to be symlinked instead of fetched from npm.
What do you see instead?
The packages are downloaded instead of being symlinked.
Additional information
Please see this repository as a real world example : https://github.com/Hebilicious/form-actions-nuxt/
If you clone it and run
bun i
, you will see thatpackages/playgrounds/simple
has anode_modules/@hebilicious/form-actions-nuxt
instead of a symlink.This happens whether
@hebilicious/form-actions-nuxt
is set to latest or to the current version.