鸿蒙通过网络加载超过5M的pag资源,下载失败
Open
@kevingpqi123 is already working on this.
Since Nov 18, 2025.
- Dominant language
- HTML
- Stars
- 5.8k
- Forks
- 531
- Avg merge
- 8d 55m
- Merged PRs (30d)
- 17
Description
【版本信息】
4.4.31
【平台信息】
鸿蒙 6.0
【预期的表现】
使用 PAGFile.LoadFromPathAsync 方法加载超过 5MB 的资源时可以正常加载
【实际的情况】
调用 PAGFile.LoadFromPathAsync 方法,会输出报错日志:“ download file failed! filePath: ”
系统错误: {"code":2300023,"message":"Failed writing received data to disk/application"}
参照华为官方文档https://developer.huawei.com/consumer/cn/doc/architecture-guides/insurance-v1_2-ts_219-0000002392863680,是因为http请求中下载文件超过5M的阈值导致图片过大而报错
希望调大限制,或者提供配置,在调用时可以根据实际情况设置阈值
【Demo及附件】
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.