mirror of
https://github.com/digital-asset/daml.git
synced 2024-09-20 01:07:18 +03:00
Set symlink_node_modules = False (#11606)
By default `yarn_install` will install `node_modules` in the repository. The advantage is that editor tooling and the like can use this `node_modules` tree without needing to duplicate it between Bazel and tooling. The downside is that Bazel has less strict control over this tree. In particular, on refetch it can happen that old files remain in the tree and confuse the build going forward. For example, we have occasionally observed errors of the form ``` warning Cannot find a suitable global folder. Tried these: "/usr/local, /does-not-exist/.yarn" ERROR The following files have the same case insensitive path, which isn't supported by the VSIX format: - extension/node_modules/form-data/Readme.md - extension/node_modules/form-data/README.md ``` Setting this flag to `False` means that `node_modules` will instead be installed under Bazel's output base and Bazel can make sure to clear the tree before a refetch. changelog_begin changelog_end Co-authored-by: Andreas Herrmann <andreas.herrmann@tweag.io>
This commit is contained in:
parent
ac19c8cff5
commit
1e0a221379
10
WORKSPACE
10
WORKSPACE
@ -1,11 +1,5 @@
|
||||
workspace(
|
||||
name = "com_github_digital_asset_daml",
|
||||
managed_directories = {
|
||||
"@npm": ["node_modules"],
|
||||
"@daml_extension_deps": ["compiler/daml-extension/node_modules"],
|
||||
"@navigator_frontend_deps": ["navigator/frontend/node_modules"],
|
||||
"@language_support_ts_deps": ["language-support/ts/packages/node_modules"],
|
||||
},
|
||||
)
|
||||
|
||||
# NOTE(JM): Load external dependencies from deps.bzl.
|
||||
@ -755,6 +749,7 @@ yarn_install(
|
||||
name = "npm",
|
||||
args = ["--frozen-lockfile"],
|
||||
package_json = "//:package.json",
|
||||
symlink_node_modules = False,
|
||||
yarn_lock = "//:yarn.lock",
|
||||
)
|
||||
|
||||
@ -763,6 +758,7 @@ yarn_install(
|
||||
name = "daml_extension_deps",
|
||||
args = ["--frozen-lockfile"],
|
||||
package_json = "//compiler/daml-extension:package.json",
|
||||
symlink_node_modules = False,
|
||||
yarn_lock = "//compiler/daml-extension:yarn.lock",
|
||||
)
|
||||
|
||||
@ -771,6 +767,7 @@ yarn_install(
|
||||
name = "navigator_frontend_deps",
|
||||
args = ["--frozen-lockfile"],
|
||||
package_json = "//navigator/frontend:package.json",
|
||||
symlink_node_modules = False,
|
||||
yarn_lock = "//navigator/frontend:yarn.lock",
|
||||
)
|
||||
|
||||
@ -784,6 +781,7 @@ yarn_install(
|
||||
name = "language_support_ts_deps",
|
||||
args = ["--frozen-lockfile"],
|
||||
package_json = "//language-support/ts/packages:package.json",
|
||||
symlink_node_modules = False,
|
||||
yarn_lock = "//language-support/ts/packages:yarn.lock",
|
||||
) if not is_windows else create_workspace(
|
||||
name = "language_support_ts_deps",
|
||||
|
Loading…
Reference in New Issue
Block a user