HarmonyOS 鸿蒙Next DevEco Studio 3.1.0.500版本从3月21日开始新建项目同步数据失败 No matching version found for @babel/helper-replace-supers@^7.24.1

HarmonyOS 鸿蒙Next DevEco Studio 3.1.0.500版本从3月21日开始新建项目同步数据失败 No matching version found for @babel/helper-replace-supers@^7.24.1

cke_758.png

Progress: resolved 141, reused 141, downloaded 0, added 0

WARN  deprecated sourcemap-codec@1.4.8: Please use @jridgewell/sourcemap-codec instead

ERR_PNPM_NO_MATCHING_VERSION  No matching version found for @babel/helper-replace-supers@^7.24.1

This error happened while installing the dependencies of @ohos/hvigor-ohos-plugin@2.1.1

at @ohos/hvigor-arkts-compose@2.1.1

at @babel/plugin-proposal-class-properties@7.8.3

at @babel/helper-create-class-features-plugin@7.24.1

The latest release of @babel/helper-replace-supers is “7.22.20”.

Other releases are:

  • esm: 7.21.4-esm.4

  • next: 8.0.0-alpha.7

If you need the full list of all 87 published versions run “$ pnpm view @babel/helper-replace-supers versions”.

Progress: resolved 181, reused 181, downloaded 0, added 0

> hvigor ERROR: C:\Users\1.hvigor\wrapper\tools\node_modules.bin\pnpm.cmd execute failed.

Process finished with exit code -1

3 回复

您好,可以考虑升级一下deveco studio的版本到4.0

https://gitee.com/openharmony/docs/tree/master/zh-cn/release-notes

更多关于HarmonyOS 鸿蒙Next DevEco Studio 3.1.0.500版本从3月21日开始新建项目同步数据失败 No matching version found for @babel/helper-replace-supers@^7.24.1的实战系列教程也可以访问 https://www.itying.com/category-93-b0.html


HarmonyOS鸿蒙Next DevEco Studio 3.1.0.500版本在3月21日后新建项目时出现同步数据失败,提示“No matching version found for @babel/helper-replace-supers@^7.24.1”,可能是由于依赖包版本不匹配或NPM仓库中缺少指定版本的包导致的。可以尝试以下步骤解决:

  1. 检查package.json文件,确认@babel/helper-replace-supers的版本是否为^7.24.1,若版本不匹配,更新到可用的最新版本。
  2. 清理NPM缓存,执行npm cache clean --force,然后重新同步项目。
  3. 若问题依旧,尝试删除node_modules文件夹和package-lock.json文件,重新执行npm install

如果问题仍未解决,可能是NPM仓库的问题,可以尝试使用其他镜像源,如淘宝NPM镜像:

npm config set registry https://registry.npm.taobao.org

然后再次执行npm install

确保DevEco Studio和Node.js版本为最新,以避免兼容性问题。

在HarmonyOS鸿蒙Next DevEco Studio 3.1.0.500版本中,新建项目时出现“No matching version found for @babel/helper-replace-supers@^7.24.1”错误,通常是由于依赖包版本不匹配或网络问题导致。建议检查网络连接,确保能访问npm仓库。如果问题依旧,可以尝试手动安装指定版本的@babel/helper-replace-supers包,或更新DevEco Studio到最新版本。

回到顶部
AI 助手
你好,我是IT营的 AI 助手
您可以尝试点击下方的快捷入口开启体验!