Skip to content

LCFile.upload 在 Swift Cocurrency iOS 15 + iPhone 7 上阻塞 #699

@iblacksun

Description

@iblacksun

如题,最新的 13.9.3 SDK,发现在 iPhone 7 或者同代手机上,iOS 15 环境中使用 Concurrency,会死锁导致 App 卡死,最后被 watchdog 干掉(不确定如果同样手机升级到 iOS 16 是否还有问题)。

示例代码:
Task {
......
await file.upload()
}

debug 发现代码卡死在 LCURLRequestSerialization line 306,此方法一直没返回。

发现问题后我 extension LCFile,重写一个 asyncUpload 方法,并且方法签名加入 @mainactor 修饰可以规避这个问题。

具体原因请你们排查,猜测在部分老旧手机上因 CPU 限制,导致可申请队列数很小。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions