HarmonyOS 鸿蒙Next M2创建项目就报错, Ide版本5.0.3.502
HarmonyOS 鸿蒙Next M2创建项目就报错, Ide版本5.0.3.502
创建项目的时候就报下面的错误,感觉是nodejs版本兼容性问题,但是不知道怎么解决,求助,求助!!!
/Applications/DevEco-Studio.app/Contents/tools/node/bin/node /Applications/DevEco-Studio.app/Contents/tools/hvigor/bin/hvigorw.js --sync -p product=default --analyze=normal --parallel --incremental --daemon
*** Terminating app due to uncaught exception ‘NSInvalidArgumentException’, reason: ‘-[__NSCFString _stringByResolvingSymlinksInPathUsingCache:]: unrecognized selector sent to instance 0x6000005ec000’
*** First throw call stack:
(
0 CoreFoundation 0x000000019248f2ec __exceptionPreprocess + 176
1 libobjc.A.dylib 0x0000000191f76788 objc_exception_throw + 60
2 CoreFoundation 0x000000019254156c -[NSObject(NSObject) __retain_OA] + 0
3 CoreFoundation 0x00000001923f8f3c forwarding + 1580
4 CoreFoundation 0x00000001923f8850 _CF_forwarding_prep_0 + 96
5 Foundation 0x00000001934f4a18 -[NSBundle initWithPath:] + 196
6 Foundation 0x00000001934f4848 +[NSBundle mainBundle] + 140
7 AppKit 0x0000000195c416a0 +[NSApplication load] + 76
8 libobjc.A.dylib 0x0000000191f67be8 load_images + 716
9 dyld 0x0000000191fc0790 _ZN5dyld412RuntimeState14notifyObjCInitEPKNS_6LoaderE + 180
10 dyld 0x0000000191fc9450 _ZNK5dyld46Loader23runInitializersBottomUpERNS_12RuntimeStateERN5dyld35ArrayIPKS0_EE + 208
11 dyld 0x0000000191fc9400 _ZNK5dyld46Loader23runInitializersBottomUpERNS_12RuntimeStateERN5dyld35ArrayIPKS0_EE + 128
12 dyld 0x0000000191fc9400 _ZNK5dyld46Loader23runInitializersBottomUpERNS_12RuntimeStateERN5dyld35ArrayIPKS0_EE + 128
13 dyld 0x0000000191fc9400 _ZNK5dyld46Loader23runInitializersBottomUpERNS_12RuntimeStateERN5dyld35ArrayIPKS0_EE + 128
14 dyld 0x0000000191fcd0ec _ZZNK5dyld46Loader38runInitializersBottomUpPlusUpwardLinksERNS_12RuntimeStateEENK3$_1clEv + 116
15 dyld 0x0000000191fc9628 _ZNK5dyld46Loader38runInitializersBottomUpPlusUpwardLinksERNS_12RuntimeStateE + 380
16 dyld 0x0000000191fe5628 _ZN5dyld44APIs11dlopen_fromEPKciPv + 1748
17 ??? 0x000000010a7280a4 0x0 + 4470243492
18 libsystem_pthread.dylib 0x000000019233af94 _pthread_start + 136
19 libsystem_pthread.dylib 0x0000000192335d34 thread_start + 8
)
libc++abi: terminating due to uncaught exception of type NSException
Process finished with exit code 134 (interrupted by signal 6:SIGABRT)
有可能装了多个node的原因,
删除多余的node,只保留其中一个。
devEco studio配置在哪呢?mac的没找到
针对HarmonyOS鸿蒙Next M2在IDE版本5.0.3.502中创建项目时遇到的报错问题,建议首先检查以下几点:
- 确保你的IDE是最新版本,或者至少是与你的鸿蒙版本兼容的版本。
- 查看报错信息,通常IDE会提供具体的错误描述或错误码,这有助于定位问题。
- 检查项目配置是否正确,包括SDK路径、环境变量等。
- 尝试清理并重建项目,有时IDE的缓存可能导致问题。
- 查看是否有相关的社区帖子或官方文档描述了类似问题。
如果问题依旧没法解决请加我微信,我的微信是itying888。