如何确定在纱线安装中要求特定的子模块?

发布于 2025-02-09 15:21:23 字数 683 浏览 2 评论 0原文

我正在节点12中运行代码。有升级计划,但这不是今天的选择。我正在尝试进行纱线安装,但是在某个地方有一些依赖性,其依赖关系的依赖性camelcase 7.0.0 ,但是,当然,这与节点不兼容12。所以我

error [email protected]: The engine "node" is incompatible with this module. Expected version ">=14.16". Got "12.22.12"
error Found incompatible module.

没有生成纱线,所以我看不到是什么原因引起的。有没有办法看到在生成纱线之前的纱线依赖树?

我已经尝试了以下内容:

% yarn why [email protected]
yarn why v1.22.19
[1/4] 
              

I am running code in node 12. There are plans to upgrade, but this is not an option today. I am trying to do a yarn install but somewhere there is some dependency with a dependency of a dependency of camelcase 7.0.0 but, of course, this is not compatible with node 12. So I get

error [email protected]: The engine "node" is incompatible with this module. Expected version ">=14.16". Got "12.22.12"
error Found incompatible module.

No yarn.lock is generated, so I can't see what is causing this. Is there a way to see what the yarn dependency tree would be before generating a yarn.lock?

I've tried the following:

% yarn why [email protected]
yarn why v1.22.19
[1/4] ????  Why do we have the module "[email protected]"...?
[2/4] ????  Initialising dependency graph...
[3/4] ????  Finding dependency...
error We couldn't find a match!
✨  Done in 1.13s.

% yarn install
yarn install v1.22.19
[1/4] ????  Resolving packages...
[2/4] ????  Fetching packages...
error [email protected]: The engine "node" is incompatible with this module. Expected version ">=14.16". Got "12.22.12"
error Found incompatible module.
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文