小程序API : wx.FileSystemManager().readFile() 的 success回调,success回调 里面 并没有data,返回的却是 {"errMsg":"readFile:ok","errno":0,"__wx_dont_hook_sdk_inner_variable_packkeys_otherwise_you_will_regret_and_occur_bug__":[]}
| 框架类型 | 问题类型 | API/组件名称 | 终端类型 | 微信版本 | 基础库版本 |
|---|---|---|---|---|---|
| 小程序 | Bug | wx.FileSystemManager().readFile | 微信安卓客户端 | 8.0.42 | 3.1.2 |
2 个回答
请具体描述问题出现的流程,并提供能复现问题的简单代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)。
function run() {let recorderManager = wx.getRecorderManager()recorderManager.onStop((file) => {const { tempFilePath } = fileif(tempFilePath) {let wxfs = wx.getFileSystemManager();wxfs.readFile({filePath: tempFilePath,success: res => {console.log(res)// 偶尔会返回以下内容:// {"errMsg":"readFile:ok","errno":0,"__wx_dont_hook_sdk_inner_variable_packkeys_otherwise_you_will_regret_and_occur_bug__":[]}}});}})recorderManager.start()}run()完整代码贴出看看