HarmonyOS 鸿蒙Next DevEco Studio 初始化依赖时,quick组件地址404

HarmonyOS 鸿蒙Next DevEco Studio 初始化依赖时,quick组件地址404

环境:
系统:Mac OS Ventura 13.1

错误日志:

347 http fetch POST 404 https://repo.huaweicloud.com/repository/npm/-/npm/v1/security/audits/quick 4484ms

348 verbose audit error HttpErrorGeneral: 404 Not Found - POST https://repo.huaweicloud.com/repository/npm/-/npm/v1/security/audits/quick

348 verbose audit error     at /Users/xingzhequ/nodejs/lib/node_modules/npm/node_modules/npm-registry-fetch/lib/check-response.js:95:15
348 verbose audit error     at runMicrotasks (<anonymous>)
348 verbose audit error     at processTicksAndRejections (node:internal/process/task_queues:96:5)
348 verbose audit error     at async Map.[getReport] (/Users/xingzhequ/nodejs/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/audit-report.js:335:21)
348 verbose audit error     at async Map.run (/Users/xingzhequ/nodejs/lib/node_modules/npm/node_modules/@npmcli/arborist/lib/audit-report.js:106:19) {
348 verbose audit error   headers: [Object: null prototype] {
348 verbose audit error     date: ['Tue, 05 Mar 2024 05:24:01 GMT'],
348 verbose audit error     'content-type': ['text/html'],
348 verbose audit error     'content-length': ['394'],
348 verbose audit error     connection: ['keep-alive'],
348 verbose audit error     server: ['openresty'],
348 verbose audit error     'set-cookie': [
348 verbose audit error       'HWWAFSESID=719c688fbc1cb182bf; path=/',
348 verbose audit error       'HWWAFSESTIME=1709616237070; path=/'
348 verbose audit error     ],
348 verbose audit error     etag: ['"65ddfc1a-18a"'],
348 verbose audit error     'x-ccdn-origin-time': ['3984'],
348 verbose audit error     via: [
348 verbose audit error       'CHN-GDdongguan-CUCC2-CACHE7[4033],CHN-GDdongguan-CUCC2-CACHE6[4025,TCP_MISS,4030],CHN-GDdongguan-GLOBAL1-CACHE39[4010],CHN-GDdongguan-GLOBAL1-CACHE57[3984,TCP_MISS,3990]'
348 verbose audit error     ],
348 verbose audit error     'x-hcs-proxy-type': ['0'],
348 verbose audit error     'x-ccdn-cachettl': ['600'],
348 verbose audit error     'x-ccdn-attack-reported': ['1'],
348 verbose audit error     'x-fetch-attempts': ['1']
348 verbose audit error   },
348 verbose audit error   statusCode: 404,
348 verbose audit error   code: 'E404',
348 verbose audit error   method: 'POST',
348 verbose audit error   uri: 'https://repo.huaweicloud.com/repository/npm/-/npm/v1/security/audits/quick',
348 verbose audit error   body: <Buffer 3c 68 74 6d 6c 3e 0a 0a 3c 68 65 61 64 3e 0a 20 20 20 20 20 20 20 20 3c 6d 65 74 61 20 68 74 74 70 2d 65 71 75 69 76 3d 22 63 6f 6e 74 65 6e 74 2d 74 ... 344 more bytes>,
348 verbose audit error   pkgid: 'quick'
348 verbose audit error }

349 silly audit error <html>

349 silly audit error <head>
349 silly audit error     <meta http-equiv="content-type" content="text/html;charset=utf-8">
349 silly audit error     <title>404</title>
349 silly audit error </head>

349 silly audit error <body>
349 silly audit error     <center>
349 silly audit error         <h1>404 Not Found</h1>
349 silly audit error     </center>
349 silly audit error     <hr>
349 silly audit error     <center>访问华为云开源镜像站,获取更多信息:<a href='https://mirrors.huaweicloud.com/'>https://mirrors.huaweicloud.com/</a></center>
349 silly audit error </body>

更多关于HarmonyOS 鸿蒙Next DevEco Studio 初始化依赖时,quick组件地址404的实战教程也可以访问 https://www.itying.com/category-93-b0.html

2 回复

您好,可能是你的配置有些问题,可以参考官网环境配置改一下

或者是这个组件下了,导致404

更多关于HarmonyOS 鸿蒙Next DevEco Studio 初始化依赖时,quick组件地址404的实战系列教程也可以访问 https://www.itying.com/category-93-b0.html


在HarmonyOS鸿蒙Next DevEco Studio初始化依赖时,遇到quick组件地址404的问题,可能是由于以下原因导致:

  1. 网络问题:检查网络连接是否正常,确保可以访问远程仓库。可以尝试使用浏览器直接访问quick组件的地址,确认是否能够正常访问。

  2. 仓库地址错误:确认在配置文件中指定的quick组件地址是否正确。如果地址错误,需要更新为正确的仓库地址。

  3. 依赖未发布或移除:检查quick组件是否已在远程仓库中发布,或者是否已被移除。如果组件未发布或已被移除,需要联系相关维护人员确认。

  4. 代理设置:如果使用了代理服务器,确保代理配置正确,并且代理服务器能够访问远程仓库。

  5. 缓存问题:清理DevEco Studio的缓存,重新初始化依赖。可以通过删除项目目录下的build文件夹或使用Clean Project功能来清理缓存。

  6. 版本兼容性:确认使用的DevEco Studio版本与quick组件版本兼容。如果版本不兼容,可能需要更新DevEco Studio或quick组件。

如果以上方法无法解决问题,建议查看DevEco Studio的日志文件,获取更多错误信息,以便进一步排查问题。

回到顶部