!53 CAPI解析doc规则检查工具初始化

Merge pull request !53 from 王曹宇/feature_check_doc
This commit is contained in:
openharmony_ci 2023-11-11 08:54:50 +00:00 committed by Gitee
commit 38776b6f9b
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
5 changed files with 3216 additions and 0 deletions

14
capi_parser/package.json Normal file
View File

@ -0,0 +1,14 @@
{
"name": "capi_parser",
"version": "1.0.0",
"description": "",
"main": "main.py",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
"dependencies": {
"comment-parser": "^1.4.1"
}
}

View File

@ -0,0 +1,338 @@
#!/usr/bin/env python
# coding=utf-8
##############################################
# Copyright (c) 2021-2022 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
##############################################
import json
import re
import subprocess
from clang.cindex import CursorKind
from typedef.check.check import ApiResultInfo, DocInfo, ErrorType, ErrorMessage, FileDocInfo, LogType, TAGS
permission_tag_rules = ['ohos.permission.HEALTH_DATA', 'ohos.permission.HEART_RATE', 'ohos.permission.ACCELERATION']
with open('./src/coreImpl/check/rules/perssion_rule.json') as json_file:
permission_file_content = json.load(json_file)
permission_tag_rules.extend([item['name'] for item in permission_file_content['module']['definePermissions']])
syscap_tag_rules: list[str] = []
with open('./src/coreImpl/check/rules/syscap_rule.json') as json_file:
syscap_tag_rules = json.load(json_file)
def create_api_result_info_by_doc(error_type: ErrorType, error: ErrorMessage, params: list[str], api_info):
error_info = str(error.value)
for param in params:
error_info = error_info.replace('$$', str(param), 1)
api_result_info = ApiResultInfo(error_type.value, error_info, api_info['name'])
api_result_info.set_type(LogType.LOG_JSDOC.value)
api_result_info.set_location(api_info['location']['location_path'])
api_result_info.set_location_line(api_info['location']['location_line'])
api_result_info.set_location_column(api_info['location']['location_column'])
return api_result_info
def create_api_result_info_by_file(error_type: ErrorType, error: ErrorMessage, params: list[str], file_info):
error_info = str(error.value)
for param in params:
error_info = error_info.replace('$$', str(param), 1)
api_result_info = ApiResultInfo(error_type.value, error_info, file_info['name'])
api_result_info.set_type(LogType.LOG_FILE.value)
return api_result_info
def process_tag_addtogroup(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
api_result_infos = []
group_name = tag_info['name']
if group_name == "":
api_result_info = create_api_result_info_by_doc(
ErrorType.EMPTY_TAG, ErrorMessage.EMPTY_TAG, [tag_info['tag']], api_info)
api_result_infos.append(api_result_info)
return api_result_infos
def process_tag_brief(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
doc_info = file_doc_info.curr_doc_info
api_result_infos = []
brief = tag_info['name'] + tag_info['description']
doc_info.brief = brief
return api_result_infos
def process_tag_deprecated(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
doc_info = file_doc_info.curr_doc_info
api_result_infos = []
name = tag_info['name']
version: str = tag_info['description']
if name != "since" or not version.isdigit():
api_result_info = create_api_result_info_by_doc(
ErrorType.UNKNOW_DEPRECATED, ErrorMessage.ERROR_INFO_VALUE_TAG, [tag_info['tag']], api_info)
api_result_infos.append(api_result_info)
doc_info.deprecated = version
return api_result_infos
def process_tag_file(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
doc_info = file_doc_info.curr_doc_info
api_result_infos = []
file_name = tag_info['name']
if file_name == "":
api_result_info = create_api_result_info_by_doc(
ErrorType.EMPTY_TAG, ErrorMessage.EMPTY_TAG, [tag_info['tag']], api_info)
api_result_infos.append(api_result_info)
doc_info.file = file_name
return api_result_infos
def process_tag_library(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
api_result_infos = []
library: str = tag_info['name'] + tag_info['description']
if not library.endswith(('.so', '.a')) and library != "NA":
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_VALUE, ErrorMessage.ERROR_INFO_VALUE_LIBRARY, [], api_info)
api_result_infos.append(api_result_info)
return api_result_infos
def process_tag_param(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
api_result_infos = []
if api_info['kind'] != CursorKind.FUNCTION_DECL.name:
return api_result_infos
index = file_doc_info.curr_doc_info.param_index
param = api_info['parm'][index]
if tag_info['name'] != param['name']:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_VALUE, ErrorMessage.ERROR_INFO_VALUE_PARAM, [index + 1, index + 1], api_info)
api_result_infos.append(api_result_info)
return api_result_infos
def process_tag_permission(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
doc_info = file_doc_info.curr_doc_info
api_result_infos = []
permission: str = tag_info['name'] + ' ' + tag_info['description']
permission_blank = re.sub(re.compile(r'\(|\)'), '', permission)
permission_join = re.sub(re.compile(r'( or | and )'), '$', permission_blank)
permission_list = permission_join.split('$')
error_permission_list = list(filter(lambda item: permission_tag_rules.index(item) == -1, permission_list))
if error_permission_list:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_VALUE, ErrorMessage.ERROR_INFO_VALUE_PERMISSION, [], api_info)
api_result_infos.append(api_result_info)
doc_info.permission = permission
return api_result_infos
def process_tag_return(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
api_result_infos = []
return api_result_infos
def process_tag_since(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
doc_info = file_doc_info.curr_doc_info
api_result_infos = []
value: str = tag_info['name'] + tag_info['description']
if value == "":
api_result_info = create_api_result_info_by_doc(
ErrorType.EMPTY_TAG, ErrorMessage.EMPTY_TAG, [tag_info['tag']], api_info)
api_result_infos.append(api_result_info)
if not value.isdigit():
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_VALUE, ErrorMessage.ERROR_INFO_VALUE_SINCE, [], api_info)
api_result_infos.append(api_result_info)
doc_info.since = tag_info['name']
return api_result_infos
def process_tag_syscap(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
doc_info = file_doc_info.curr_doc_info
api_result_infos = []
syscap = tag_info['name'] + tag_info['description']
if syscap == "":
api_result_info = create_api_result_info_by_doc(
ErrorType.EMPTY_TAG, ErrorMessage.EMPTY_TAG, [tag_info['tag']], api_info)
api_result_infos.append(api_result_info)
if syscap_tag_rules.index(syscap) == -1:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_VALUE, ErrorMessage.ERROR_INFO_VALUE_SYSCAP, [], api_info)
api_result_infos.append(api_result_info)
doc_info.syscap = syscap
return api_result_infos
def process_tag_left_brace(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
api_result_infos = []
if not file_doc_info.is_in_group_tag:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_USE_LEFT_BRACE, [], api_info)
api_result_infos.append(api_result_info)
return api_result_infos
def process_tag_right_brace(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
api_result_infos = []
if not file_doc_info.has_group_end:
file_doc_info.has_group_end = True
return api_result_infos
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_USE_RIGHT_BRACE, [], api_info)
api_result_infos.append(api_result_info)
return api_result_infos
process_tag_function = {
TAGS['ADD_TO_GROUP'].value: process_tag_addtogroup,
TAGS['BRIEF'].value: process_tag_brief,
TAGS['DEPRECATED'].value: process_tag_deprecated,
TAGS['FILE'].value: process_tag_file,
TAGS['LIBRARY'].value: process_tag_library,
TAGS['PARAM'].value: process_tag_param,
TAGS['PERMISSION'].value: process_tag_permission,
TAGS['RETURN'].value: process_tag_return,
TAGS['SINCE'].value: process_tag_since,
TAGS['SYSCAP'].value: process_tag_syscap,
TAGS['LEFT_BRACE'].value: process_tag_left_brace,
TAGS['RIGHT_BRACE'].value: process_tag_right_brace,
}
def process_each_tags(tag_info, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
'''
处理解析出来的每个tag标签
'''
doc_info = file_doc_info.curr_doc_info
tag = tag_info['tag']
if tag not in process_tag_function.keys():
return []
tag_process = process_tag_function[tag]
if tag == TAGS['PARAM'].value:
doc_info.param_index += 1
api_result_infos = tag_process(
tag_info, file_doc_info, api_info)
return api_result_infos
def process_file_doc_group(file_doc_info: FileDocInfo, item, api_info) -> list[ApiResultInfo]:
'''
处理每个文件中头文件中的addtogroup
'''
api_result_infos = []
if item['tag'] == 'addtogroup':
if file_doc_info.group_name is None:
file_doc_info.group_name = item['name']
file_doc_info.is_in_group_tag = True
else:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.REPEAT_FILE_TAG, [item['tag']], api_info)
api_result_infos.append(api_result_info)
if item['tag'] == '{':
if not file_doc_info.has_group_start:
file_doc_info.has_group_start = True
else:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_REPEAT_LEFT_BRACE, [item['tag']], api_info)
api_result_infos.append(api_result_info)
return api_result_infos
def process_file_doc_file(file_doc_info: FileDocInfo, item, api_info) -> list[ApiResultInfo]:
'''
处理每个文件中头文件中的file
'''
api_result_infos = []
if item['tag'] == 'file':
if file_doc_info.file_name is None:
file_doc_info.file_name = item['name']
file_doc_info.is_in_file_tag = True
else:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.REPEAT_FILE_TAG, [item['tag']], api_info)
api_result_infos.append(api_result_info)
elif item['tag'] == 'brief':
file_doc_info.file_brief = item['name'] + item['description']
elif item['tag'] == 'library':
file_doc_info.file_library = item['name'] + item['description']
elif item['tag'] == 'syscap':
file_doc_info.file_syscap = item['name'] + item['description']
return api_result_infos
def process_comment(comment: str, file_doc_info: FileDocInfo, api_info) -> list[ApiResultInfo]:
'''
处理comment数据通过node调用comment-parser解析doc注释
'''
api_result_infos = []
result = subprocess.check_output(['node', './src/coreImpl/check/comment_parser.js', comment]) # 解析comment
result_json = json.loads(result.decode('utf-8'))
tags = result_json[0]['tags']
file_doc_info.curr_doc_info = DocInfo() # 每段doc返回的数据格式
for item in tags:
# 处理文件组数据,一个文件只有一个,是否需要判断多个存在?
if item['tag'] == 'addtogroup' or file_doc_info.is_in_group_tag:
api_result_infos.extend(process_file_doc_group(file_doc_info, item, api_info))
# 处理文件中file说明一个文件只有一个是否需要判断多个存在
if item['tag'] == 'file' or file_doc_info.is_in_file_tag:
api_result_infos.extend(process_file_doc_file(file_doc_info, item, api_info))
api_result_infos.extend(process_each_tags(item, file_doc_info, api_info))
# 判断param标签的数量和方法参数的数量是否对应
if api_info['kind'] == CursorKind.FUNCTION_DECL.name:
if len(api_info['parm']) != file_doc_info.curr_doc_info.param_index + 1:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_INFO_COUNT_PARAM, [], api_info)
api_result_infos.append(api_result_info)
# 判断group标签的开头
if file_doc_info.is_in_group_tag and not file_doc_info.has_group_start:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_FILE_HAS_ONE_LOSE_OTHER, ['group tag', 'start tag {'], api_info)
api_result_infos.append(api_result_info)
# 处理file标签的值
if file_doc_info.is_in_file_tag:
if file_doc_info.file_brief is None:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_FILE_HAS_ONE_LOSE_OTHER, ['file tag', 'brief tag'], api_info)
api_result_infos.append(api_result_info)
if file_doc_info.file_library is None:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_FILE_HAS_ONE_LOSE_OTHER, ['file tag', 'library tag'], api_info)
api_result_infos.append(api_result_info)
if file_doc_info.file_syscap is None:
api_result_info = create_api_result_info_by_doc(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_FILE_HAS_ONE_LOSE_OTHER, ['file tag', 'syscap tag'], api_info)
api_result_infos.append(api_result_info)
file_doc_info.is_in_group_tag = False # 初始化group标签判断
file_doc_info.is_in_file_tag = False # 初始化file标签判断
return api_result_infos
def process_file_doc_info(file_doc_info: FileDocInfo, file_info):
api_result_infos = []
# 处理group说明
if file_doc_info.group_name is None:
api_result_info = create_api_result_info_by_file(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_FILE_LOSE_ONE, ['group doc'], file_info)
api_result_infos.append(api_result_info)
else:
# 判断group标签的结尾
if not file_doc_info.has_group_end:
api_result_info = create_api_result_info_by_file(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_LOSE_GROUP_END, ['group tag', 'end tag }'], file_info)
api_result_infos.append(api_result_info)
# 处理file说明
if file_doc_info.file_name is None:
api_result_info = create_api_result_info_by_file(
ErrorType.WRONG_SCENE, ErrorMessage.ERROR_FILE_LOSE_ONE, ['file doc'], file_info)
api_result_infos.append(api_result_info)
return api_result_infos

View File

@ -0,0 +1,31 @@
/*
* Copyright (c) 2021-2022 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
const { parse } = require('comment-parser');
const SECOND_PARAM = 2;
/**
* 解析节点的JSDoc信息可能包含多段
*
* @param {string[]} jsdocText
* @returns {Array}
*/
function parseJSDocs(jsdocText) {
const result = parse(jsdocText);
return result;
}
const commentStr = process.argv[SECOND_PARAM];
const value = parseJSDocs(commentStr);
console.log(JSON.stringify(value));

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,246 @@
[
"SystemCapability.Applications.CalendarData",
"SystemCapability.ArkUI.ArkUI.Full",
"SystemCapability.ArkUI.ArkUI.Lite",
"SystemCapability.ArkUI.ArkUI.Napi",
"SystemCapability.ArkUI.ArkUI.Libuv",
"SystemCapability.ArkUI.UiAppearance",
"SystemCapability.BundleManager.BundleFramework",
"SystemCapability.BundleManager.DistributedBundleFramework",
"SystemCapability.BundleManager.Zlib",
"SystemCapability.BundleManager.BundleFramework.Core",
"SystemCapability.BundleManager.BundleFramework.FreeInstall",
"SystemCapability.BundleManager.BundleFramework.Resource",
"SystemCapability.BundleManager.BundleFramework.DefaultApp",
"SystemCapability.BundleManager.BundleFramework.Launcher",
"SystemCapability.BundleManager.BundleFramework.SandboxApp",
"SystemCapability.BundleManager.BundleFramework.QuickFix",
"SystemCapability.BundleManager.BundleFramework.AppControl",
"SystemCapability.BundleManager.BundleFramework.Overlay",
"SystemCapability.Developtools.Syscap",
"SystemCapability.Graphic.Graphic2D.WebGL",
"SystemCapability.Graphic.Graphic2D.WebGL2",
"SystemCapability.Graphic.Graphic2D.ColorManager.Core",
"SystemCapability.Graphic.Vulkan",
"SystemCapability.Window.SessionManager",
"SystemCapability.WindowManager.WindowManager.Core",
"SystemCapability.WindowManager.WindowManager.MutiScreen",
"SystemCapability.Notification.CommonEvent",
"SystemCapability.Notification.Notification",
"SystemCapability.Notification.ReminderAgent",
"SystemCapability.Notification.Emitter",
"SystemCapability.Communication.IPC.Core",
"SystemCapability.Communication.SoftBus.Core",
"SystemCapability.Communication.NetManager.Core",
"SystemCapability.Communication.NetManager.Extension",
"SystemCapability.Communication.NetStack",
"SystemCapability.Communication.WiFi.Core",
"SystemCapability.Communication.WiFi.STA",
"SystemCapability.Communication.WiFi.AP.Core",
"SystemCapability.Communication.WiFi.AP.Extension",
"SystemCapability.Communication.WiFi.P2P",
"SystemCapability.Communication.Bluetooth.Core",
"SystemCapability.Communication.Bluetooth.Lite",
"SystemCapability.Communication.NFC.Core",
"SystemCapability.Communication.ConnectedTag",
"SystemCapability.Communication.NFC.Tag",
"SystemCapability.Communication.NFC.CardEmulation",
"SystemCapability.Communication.NetManager.Ethernet",
"SystemCapability.Communication.NetManager.NetSharing",
"SystemCapability.Communication.NetManager.MDNS",
"SystemCapability.Communication.NetManager.Vpn",
"SystemCapability.Communication.SecureElement",
"SystemCapability.Location.Location.Core",
"SystemCapability.Location.Location.Geocoder",
"SystemCapability.Location.Location.Geofence",
"SystemCapability.Location.Location.Gnss",
"SystemCapability.Location.Location.Lite",
"SystemCapability.Msdp.DeviceStatus.Stationary",
"SystemCapability.MultimodalInput.Input.Core",
"SystemCapability.MultimodalInput.Input.InputDevice",
"SystemCapability.MultimodalInput.Input.RemoteInputDevice",
"SystemCapability.MultimodalInput.Input.InputMonitor",
"SystemCapability.MultimodalInput.Input.InputConsumer",
"SystemCapability.MultimodalInput.Input.InputSimulator",
"SystemCapability.MultimodalInput.Input.InputFilter",
"SystemCapability.MultimodalInput.Input.Cooperator",
"SystemCapability.MultimodalInput.Input.Pointer",
"SystemCapability.PowerManager.BatteryManager.Extension",
"SystemCapability.PowerManager.BatteryStatistics",
"SystemCapability.PowerManager.DisplayPowerManager",
"SystemCapability.PowerManager.DisplayPowerManager.Lite",
"SystemCapability.PowerManager.ThermalManager",
"SystemCapability.PowerManager.PowerManager.Core",
"SystemCapability.PowerManager.PowerManager.Lite",
"SystemCapability.PowerManager.BatteryManager.Core",
"SystemCapability.PowerManager.BatteryManager.Lite",
"SystemCapability.PowerManager.PowerManager.Extension",
"SystemCapability.Multimedia.Media.Core",
"SystemCapability.Multimedia.Media.AudioPlayer",
"SystemCapability.Multimedia.Media.AudioRecorder",
"SystemCapability.Multimedia.Media.VideoPlayer",
"SystemCapability.Multimedia.Media.VideoRecorder",
"SystemCapability.Multimedia.Media.CodecBase",
"SystemCapability.Multimedia.Media.AudioDecoder",
"SystemCapability.Multimedia.Media.AudioEncoder",
"SystemCapability.Multimedia.Media.VideoDecoder",
"SystemCapability.Multimedia.Media.VideoEncoder",
"SystemCapability.Multimedia.Media.Spliter",
"SystemCapability.Multimedia.Media.Muxer",
"SystemCapability.Multimedia.Media.AVScreenCapture",
"SystemCapability.Multimedia.Media.SoundPool",
"SystemCapability.Multimedia.AVSession.Core",
"SystemCapability.Multimedia.AVSession.Manager",
"SystemCapability.Multimedia.AVSession.AVCast",
"SystemCapability.Multimedia.Audio.Core",
"SystemCapability.Multimedia.Audio.Tone",
"SystemCapability.Multimedia.Audio.Interrupt",
"SystemCapability.Multimedia.Audio.Renderer",
"SystemCapability.Multimedia.Audio.Capturer",
"SystemCapability.Multimedia.Audio.Device",
"SystemCapability.Multimedia.Audio.Volume",
"SystemCapability.Multimedia.Audio.Communication",
"SystemCapability.Multimedia.Audio.PlaybackCapture",
"SystemCapability.Multimedia.Camera.Core",
"SystemCapability.Multimedia.Camera.DistributedCore",
"SystemCapability.Multimedia.Image.Core",
"SystemCapability.Multimedia.Image.ImageSource",
"SystemCapability.Multimedia.Image.ImagePacker",
"SystemCapability.Multimedia.Image.ImageReceiver",
"SystemCapability.Multimedia.MediaLibrary.Core",
"SystemCapability.Multimedia.MediaLibrary.SmartAlbum",
"SystemCapability.Multimedia.MediaLibrary.DistributedCore",
"SystemCapability.Multimedia.Media.AVPlayer",
"SystemCapability.Multimedia.Media.AVRecorder",
"SystemCapability.Multimedia.Image.ImageCreator",
"SystemCapability.Multimedia.SystemSound.Core",
"SystemCapability.Telephony.CoreService",
"SystemCapability.Telephony.CallManager",
"SystemCapability.Telephony.CellularCall",
"SystemCapability.Telephony.CellularData",
"SystemCapability.Telephony.SmsMms",
"SystemCapability.Telephony.StateRegistry",
"SystemCapability.Global.I18n",
"SystemCapability.Global.ResourceManager",
"SystemCapability.Customization.ConfigPolicy",
"SystemCapability.Customization.EnterpriseDeviceManager",
"SystemCapability.BarrierFree.Accessibility.Core",
"SystemCapability.BarrierFree.Accessibility.Vision",
"SystemCapability.BarrierFree.Accessibility.Hearing",
"SystemCapability.BarrierFree.Accessibility.Interaction",
"SystemCapability.ResourceSchedule.WorkScheduler",
"SystemCapability.ResourceSchedule.BackgroundTaskManager.ContinuousTask",
"SystemCapability.ResourceSchedule.BackgroundTaskManager.TransientTask",
"SystemCapability.ResourceSchedule.UsageStatistics.App",
"SystemCapability.ResourceSchedule.UsageStatistics.AppGroup",
"SystemCapability.ResourceSchedule.BackgroundTaskManager.EfficiencyResourcesApply",
"SystemCapability.Utils.Lang",
"SystemCapability.HiviewDFX.HiLog",
"SystemCapability.HiviewDFX.HiLogLite",
"SystemCapability.HiviewDFX.HiTrace",
"SystemCapability.HiviewDFX.Hiview.FaultLogger",
"SystemCapability.HiviewDFX.Hiview.LogLibrary",
"SystemCapability.HiviewDFX.HiviewLite",
"SystemCapability.HiviewDFX.HiChecker",
"SystemCapability.HiviewDFX.HiCollie",
"SystemCapability.HiviewDFX.HiDumper",
"SystemCapability.HiviewDFX.HiAppEvent",
"SystemCapability.HiviewDFX.HiSysEvent",
"SystemCapability.HiviewDFX.HiEventLite",
"SystemCapability.HiviewDFX.HiProfiler.HiDebug",
"SystemCapability.Update.UpdateService",
"SystemCapability.DistributedHardware.DeviceManager",
"SystemCapability.Security.DeviceAuth",
"SystemCapability.Security.DataTransitManager",
"SystemCapability.Security.DeviceSecurityLevel",
"SystemCapability.Security.Huks.Core",
"SystemCapability.Security.Huks.Extension",
"SystemCapability.Security.AccessToken",
"SystemCapability.Security.Cipher",
"SystemCapability.Security.CertificateManager",
"SystemCapability.Security.CryptoFramework",
"SystemCapability.Security.CryptoFramework.Cert",
"SystemCapability.Security.DataLossPrevention",
"SystemCapability.Security.Cert",
"SystemCapability.Account.OsAccount",
"SystemCapability.Account.AppAccount",
"SystemCapability.UserIAM.UserAuth.Core",
"SystemCapability.UserIAM.UserAuth.PinAuth",
"SystemCapability.UserIAM.UserAuth.FaceAuth",
"SystemCapability.MiscServices.InputMethodFramework",
"SystemCapability.MiscServices.Pasteboard",
"SystemCapability.MiscServices.Time",
"SystemCapability.MiscServices.Wallpaper",
"SystemCapability.MiscServices.ScreenLock",
"SystemCapability.MiscServices.Upload",
"SystemCapability.MiscServices.Download",
"SystemCapability.FileManagement.StorageService.Backup",
"SystemCapability.FileManagement.StorageService.SpatialStatistics",
"SystemCapability.FileManagement.StorageService.Volume",
"SystemCapability.FileManagement.StorageService.Encryption",
"SystemCapability.FileManagement.File.FileIO",
"SystemCapability.FileManagement.File.FileIO.Lite",
"SystemCapability.FileManagement.File.Environment",
"SystemCapability.FileManagement.File.DistributedFile",
"SystemCapability.FileManagement.AppFileService",
"SystemCapability.FileManagement.UserFileService",
"SystemCapability.FileManagement.UserFileManager",
"SystemCapability.FileManagement.UserFileManager.DistributedCore",
"SystemCapability.FileManagement.UserFileManager.Core",
"SystemCapability.USB.USBManager",
"SystemCapability.Sensors.Sensor",
"SystemCapability.Sensors.MiscDevice",
"SystemCapability.Sensors.Sensor.Lite",
"SystemCapability.Sensors.MiscDevice.Lite",
"SystemCapability.Startup.SystemInfo",
"SystemCapability.Startup.SystemInfo.Lite",
"SystemCapability.DistributedDataManager.RelationalStore.Core",
"SystemCapability.DistributedDataManager.RelationalStore.Synchronize",
"SystemCapability.DistributedDataManager.RelationalStore.Lite",
"SystemCapability.DistributedDataManager.KVStore.Core",
"SystemCapability.DistributedDataManager.KVStore.Lite",
"SystemCapability.DistributedDataManager.KVStore.DistributedKVStore",
"SystemCapability.DistributedDataManager.DataObject.DistributedObject",
"SystemCapability.DistributedDataManager.Preferences.Core",
"SystemCapability.DistributedDataManager.DataShare.Core",
"SystemCapability.DistributedDataManager.DataShare.Consumer",
"SystemCapability.DistributedDataManager.DataShare.Provider",
"SystemCapability.DistributedDataManager.UDMF.Core",
"SystemCapability.DistributedDataManager.CloudSync.Config",
"SystemCapability.DistributedDataManager.CloudSync.Client",
"SystemCapability.DistributedDataManager.CloudSync.Server",
"SystemCapability.Ability.AbilityBase",
"SystemCapability.Ability.AbilityRuntime.Core",
"SystemCapability.Ability.AbilityRuntime.FAModel",
"SystemCapability.Ability.AbilityRuntime.AbilityCore",
"SystemCapability.Ability.AbilityRuntime.Mission",
"SystemCapability.Ability.AbilityTools.AbilityAssistant",
"SystemCapability.Ability.Form",
"SystemCapability.Ability.DistributedAbilityManager",
"SystemCapability.Ability.AbilityRuntime.QuickFix",
"SystemCapability.Applications.ContactsData",
"SystemCapability.Applications.Contacts",
"SystemCapability.Applications.settings.Core",
"SystemCapability.Test.UiTest",
"SystemCapability.Web.Webview.Core",
"SystemCapability.Cloud.AAID",
"SystemCapability.Advertising.OAID",
"SystemCapability.Cloud.VAID",
"SystemCapability.Cloud.Push",
"SystemCapability.XTS.DeviceAttest",
"SystemCapability.XTS.DeviceAttestLite",
"SystemCapability.Base",
"SystemCapability.FileManagement.DistributedFileService.CloudSyncManager",
"SystemCapability.FileManagement.DistributedFileService.CloudSync.Core",
"SystemCapability.MultimodalInput.Input.ShortKey",
"SystemCapability.Msdp.DeviceStatus.Cooperate",
"SystemCapability.Request.FileTransferAgent",
"SystemCapability.ResourceSchedule.DeviceStandby",
"SystemCapability.AI.MindSporeLite",
"SystemCapability.Print.PrintFramework",
"SystemCapability.DistributedDataManager.Preferences.Core.Lite",
"SystemCapability.Driver.ExternalDevice",
"SystemCapability.FileManagement.PhotoAccessHelper.Core",
"SystemCapability.AI.IntelligentVoice.Core",
"SystemCapability.Msdp.DeviceStatus.Drag"
]