ZLPhotoBrowser icon indicating copy to clipboard operation
ZLPhotoBrowser copied to clipboard

iOS 26 选择照片闪退,其他版本没问题

Open frankfffff opened this issue 3 months ago • 12 comments

frankfffff avatar Sep 16 '25 06:09 frankfffff

目前手里没有iOS26的设备,能debug下看下堆栈吗

longitachi avatar Sep 17 '25 06:09 longitachi

collectionView. performBatchUpdates貌似有问题,可以模拟器试试,偶现的

zidonJ avatar Sep 29 '25 07:09 zidonJ

我似乎收到了同样的反馈,我并不清楚是怎么发生的。 同样是iOS26的用户. let insertIndexPath = IndexPath(row: insertIndex, section: 0) collectionView.performBatchUpdates { self.collectionView.insertItems(at: [insertIndexPath]) } completion: { _ in self.collectionView.scrollToItem(at: insertIndexPath, at: .centeredVertically, animated: true) self.collectionView.reloadItems(at: self.collectionView.indexPathsForVisibleItems) } 崩溃在了 self.collectionView.insertItems(at: [insertIndexPath]) 这一行

EchoLunar avatar Oct 03 '25 05:10 EchoLunar

感觉是不是可以不用performBatchUpdates @longitachi

zidonJ avatar Oct 10 '25 08:10 zidonJ

感觉是不是可以不用performBatchUpdates @longitachi

ai建议放到下一次runloop

zidonJ avatar Oct 10 '25 10:10 zidonJ

贴一下你们相册的调用代码吧,我看下你们的配置参数。 以及有没有完整的复现路径?

longitachi avatar Oct 13 '25 07:10 longitachi

贴一下你们相册的调用代码吧,我看下你们的配置参数。 以及有没有完整的复现路径?

bugly提示的 不止iOS26,没有闪退路径,另外有个问题 ZLEditImageViewController.swift, let editSize = editRect.size,除数有可能为0 Nan闪退,无法复现 准备fork一下,performBatchUpdates放到下一个runloop试试看是否起作用,闪退数量有点多,好用的话我再反馈

zidonJ avatar Oct 13 '25 08:10 zidonJ

@zidonJ 用的哪个版本?如果最新版本的话可以禁止下分页加载试试ZLPhotoUIConfiguration.default.allowPageLoading = false,不确定是不是这个原因

longitachi avatar Oct 13 '25 12:10 longitachi

我找了个iOS26设备,用demo测试了进入相册、拍照、选择图片、以及完全访问及受限访问权限等功能没有遇到crash,贴下你们相册调用代码吧,以及设备中有多少张照片。

longitachi avatar Oct 14 '25 03:10 longitachi

贴一下你们相册的调用代码吧,我看下你们的配置参数。 以及有没有完整的复现路径?

bugly提示的 不止iOS26,没有闪退路径,另外有个问题 ZLEditImageViewController.swift, let editSize = editRect.size,除数有可能为0 Nan闪退,无法复现 准备fork一下,performBatchUpdates放到下一个runloop试试看是否起作用,闪退数量有点多,好用的话我再反馈

我这的bugly显示崩溃在 override func viewWillAppear(_ animated: Bool) { super.viewWillAppear(animated) navigationController?.navigationBar.isHidden = true collectionView.reloadItems(at: collectionView.indexPathsForVisibleItems) resetBottomToolBtnStatus() } 这里。Invalid update: invalid number of items in section 0.

RoyChen-Nan-cmd avatar Oct 16 '25 03:10 RoyChen-Nan-cmd

@RoyChen-Nan-cmd 你这个是必现吗?看代码不是最新版本。 更新下版本,或者直接指向最新提交的commit

longitachi avatar Oct 16 '25 06:10 longitachi

@RoyChen-Nan-cmd 你这个是必现吗?看代码不是最新版本。 更新下版本,或者直接指向最新提交的commit

不是必现的。已经更新到最新版本,我再观察下。

RoyChen-Nan-cmd avatar Oct 17 '25 03:10 RoyChen-Nan-cmd