当前位置:   article > 正文

鸿蒙隐私权限报错-ERROR: Failed :entry:default@PreBuild... ERROR: Schema validate failed._> hvigor error: failed :entry:default@prebuild...

> hvigor error: failed :entry:default@prebuild...

报错信息:> hvigor ERROR: Failed :entry:default@PreBuild... 
> hvigor ERROR: Schema validate failed.
     Detail: Please check the following fields.
{
  instancePath: 'module.requestPermissions[0].reason',
  keyword: 'pattern',
  params: {
    pattern: '^[$]string:[0-9a-zA-Z_.]+|(?=.*[{])(?=.*[}])[0-9a-zA-Z_.{}]+$'
  },
  message: 'must match pattern "^[$]string:[0-9a-zA-Z_.]+|(?=.*[{])(?=.*[}])[0-9a-zA-Z_.{}]+$"',
  location: '/Users/mac/DevEcoStudioProjects/MyFristHMProject/entry/src/main/module.json5:41:28'

> hvigor ERROR: BUILD FAILED in 137 ms 

原因:module.json5  隐私权限设置是自己自定义的名字,reason必须为系统的

修改后:运行成功

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/知新_RL/article/detail/226507
推荐阅读
相关标签
  

闽ICP备14008679号