HarmonyOS 鸿蒙Next设备模拟器版本不匹配
HarmonyOS 鸿蒙Next设备模拟器版本不匹配
我安装了 crypto-js 库
```bash
ohpm install [@ohos](/user/ohos)/crypto-js
运行报错
ERROR: The compatibleSdkVersion 9 cannot be smaller than version 10 declared in library [:crypto]
as the library might be using APIS not available in 9
我把sdk升级到10
"compileSdkVersion": 10,
"compatibleSdkVersion": 10,
设备管理器中 没有api为10的模拟器 运行报错
Failure[INSTALL_PARSE_FAILED_USESDK_ERROR]
我应该怎么办
更多关于HarmonyOS 鸿蒙Next设备模拟器版本不匹配的实战教程也可以访问 https://www.itying.com/category-93-b0.html
我重新建了一个项目
直接安装高版本没有问题
更多关于HarmonyOS 鸿蒙Next设备模拟器版本不匹配的实战系列教程也可以访问 https://www.itying.com/category-93-b0.html
DevEco Studio中暂未提供API10,需要等到2024年第一季度正式面对所有开发者。当三方库中限制了API最低版本时,则无法使用。可以在三方库提issue,或者等明年一季度。
这个问题解决了
升级版本到2.0.3-rc.0 解决上述问题
遇到新的问题
10-27 14:27:45.347 190-190/? E SELinux/ : avc: denied { find } for pid=13433 uid=0 name=testharness scontext=u:r:ohco_containerd:s0 tcontext=u:object_r:testharness_service:s0 tclass=service_manager permissive=1
10-27 14:27:45.352 695-695/? E selinux_dmd/: avc: denied { find } for dsm=hisi_Q pid=13433 uid=0 name=testharness scontext=u:r:ohco_containerd:s0 tcontext=u:object_r:testharness_service:s0 tclass=service_manager permissive=1 CMD=/system/bin/containerd
10-27 14:27:45.352 695-695/? E selinux_dmd/: ReportImonitor:ohco_containerd testharness_service:service_manager { find }/system/bin/containerd failed
10-27 14:27:47.565 13515-22/? E 02C02/PARAM: [param_comm.c:140]Forbid to access parameter persist.sys.hiview.testtype
10-27 14:27:47.565 13515-22/? E 02C02/PARAM: [param_request.c:255]Forbid to watch parameter persist.sys.hiview.testtype
HarmonyOS 鸿蒙Next设备模拟器版本不匹配问题通常是由于模拟器与开发环境或系统版本不一致导致的。开发者在进行应用调试时,需要确保使用的设备模拟器版本与当前HarmonyOS SDK版本兼容。开发者可以通过检查SDK Manager中的模拟器版本,确保其与项目构建目标版本一致。若版本不匹配,需更新模拟器或SDK至兼容版本。此外,开发者在创建模拟器时,应选择与目标设备相同的系统镜像版本,以避免版本不匹配问题。若问题持续,需检查开发环境配置,确保所有相关工具的版本一致性。