""" 华为应用市场已知的鸿蒙应用ID列表 从 guess.py 分析得出,共962个ID """ # 导入ID列表的函数 def load_app_ids(): """加载应用ID列表""" import os import sys # 从同目录下的 guess.py 导入 guess_file = os.path.join(os.path.dirname(__file__), 'guess.py') if os.path.exists(guess_file): # 读取 guess.py 中的 ids 列表 with open(guess_file, 'r', encoding='utf-8') as f: content = f.read() # 提取 ids 列表部分 start = content.find('ids = [') end = content.find(']', start) + 1 ids_code = content[start:end] # 执行代码获取 ids local_vars = {} exec(ids_code, {}, local_vars) return local_vars['ids'] # 如果文件不存在,返回默认的前20个ID return [ 6917559067092904725, 6917559133889396578, 6917559134045802769, 6917559138770331354, 6917559303873561126, 6917559384755888642, 6917559398244134093, 6917559401760179700, 6917559412599401190, 6917559420741644814, 6917559471584581139, 6917559493442858602, 6917559997337903225, 6917560000979877756, 6917560003449022390, 6917560016672900552, 6917560022799490908, 6917560032190348725, 6917560035472143514, 6917560097545123074, ] # 全局变量:应用ID列表 KNOWN_APP_IDS = load_app_ids()