DevEco-Studio运行工程报错指向build-profile.json5,ERROR:Solution:please check the following fields
报错信息:
> hvigor ERROR: Schema validate failed.
Detail: Please check the following fields.
{
instancePath: 'app',
keyword: 'required',
params: { missingProperty: 'compileSdkVersion' },
message: "must have required property 'compileSdkVersion'",
location: '/Users/xxx/Desktop/xxx/xxx/xxx/build-profile.json5:2:11'
}
实际上build-profile.json5都有上述字段
解决办法:可以把工程下的node_modules删了,然后再sync一下运行,大概率是因为node_modules下旧版本的hvigor和当前工程下新版本的hvigor冲突了。