dji-sdk / Mobile-UXSDK-iOS

DJI Mobile UXSDK is a suite of product agnostic UI objects that fast tracks the development of iOS applications using the DJI Mobile SDK.
Other
73 stars 43 forks source link

subarrayWithRange crash on 4.14 SDK Mavic Mini #101

Open AdamKraif opened 3 years ago

AdamKraif commented 3 years ago

Hi,

SDK - 4.14 / 4.14-trial1 Drone - Mavic mini Firmware - 01.00.0500 Phone - IphoneSE, Iphone11, iphone11Max, iphoneX (Those are the ones that we tested on but it looks like the problem can recreate at all iPhone models) Version - >14.0

The crash :

Terminating app due to uncaught exception 'NSRangeException', reason: '* -[NSArray subarrayWithRange:]: range {0, 9223372036854775808} extends beyond bounds for empty array' terminating with uncaught exception of type NSException

The stack trace:

0 CoreFoundation 0x00000001a6f89880 727F2644-EB4E-3D57-BC2E-E6803BA92366 + 1202304 1 libobjc.A.dylib 0x00000001bbfa4c50 objc_exception_throw + 60 2 CoreFoundation 0x00000001a6ff9e1c 727F2644-EB4E-3D57-BC2E-E6803BA92366 + 1662492 3 CoreFoundation 0x00000001a6e80ff0 727F2644-EB4E-3D57-BC2E-E6803BA92366 + 118768 4 DJIUXSDK 0x000000010ef78cf0 -[DUXWidgetCollectionViewStacksLayout frameOfWidgetAtIndex:] + 324 5 DJIUXSDK 0x000000010ef78b04 -[DUXWidgetCollectionViewStacksLayout layoutAttributesForItemAtIndexPath:] + 244 6 DJIUXSDK 0x000000010ee9c2b0 -[DUXWidgetCollectionViewLayout layoutAttributesForElementsInRect:] + 316 7 UIKitCore 0x00000001a90876cc 8518EAE3-832B-3FF0-9FA5-9DBE3041F26C + 3217100 8 UIKitCore 0x00000001a9086e54 8518EAE3-832B-3FF0-9FA5-9DBE3041F26C + 3214932 9 UIKitCore 0x00000001a90503c0 8518EAE3-832B-3FF0-9FA5-9DBE3041F26C + 2991040 10 UIKitCore 0x00000001a9e8bec4 8518EAE3-832B-3FF0-9FA5-9DBE3041F26C + 17915588 11 QuartzCore 0x00000001aa3a6644 8510F139-0824-3686-A9AA-3E198539A021 + 1439300 12 QuartzCore 0x00000001aa3a6b18 8510F139-0824-3686-A9AA-3E198539A021 + 1440536 13 QuartzCore 0x00000001aa3bb30c 8510F139-0824-3686-A9AA-3E198539A021 + 1524492 14 QuartzCore 0x00000001aa300640 8510F139-0824-3686-A9AA-3E198539A021 + 759360 15 QuartzCore 0x00000001aa32bb08 8510F139-0824-3686-A9AA-3E198539A021 + 936712 16 QuartzCore 0x00000001aa32ce98 8510F139-0824-3686-A9AA-3E198539A021 + 941720 17 CoreFoundation 0x00000001a6f04358 727F2644-EB4E-3D57-BC2E-E6803BA92366 + 656216 18 CoreFoundation 0x00000001a6efe5c4 727F2644-EB4E-3D57-BC2E-E6803BA92366 + 632260 19 CoreFoundation 0x00000001a6efeb74 727F2644-EB4E-3D57-BC2E-E6803BA92366 + 633716 20 CoreFoundation 0x00000001a6efe21c CFRunLoopRunSpecific + 600 21 GraphicsServices 0x00000001beaca784 GSEventRunModal + 164 22 UIKitCore 0x00000001a993eee8 8518EAE3-832B-3FF0-9FA5-9DBE3041F26C + 12357352 23 UIKitCore 0x00000001a994475c UIApplicationMain + 168 24 UXSDKDemo 0x00000001026ef9b0 main + 112 25 libdyld.dylib 0x00000001a6bbe6b0 21B19919-1334-38BC-B233-896E929945E0 + 5808

Please provide a solution Thanks.

ron10023 commented 3 years ago

Happens to me as well on IPhone Xr.

Following

dji-dev commented 3 years ago

Agent comment from Luce Luo in Zendesk ticket #49570:

Dear Customer,

Thank you for contacting DJI. Sorry that this problem has been escalated to the engineer to investigate. It will cost some time and we will contact us again once any progress.

Thanks,

Luce Luo DJI Developer Support

°°°

AdamKraif commented 2 years ago

This issue is also happening in Matrice 300

DJI-William commented 2 years ago

@AdamKraif We are working on this issue now, is there any reprocueable method for us, so that we can test locally.

dji-dev commented 2 years ago

Agent comment from DJI SDK in Zendesk ticket #49570:

尊敬的开发者,感谢您联系DJI 大疆创新 由于github不是我们主要的咨询渠道,您的问题可能跟进不及时。我们建议您通过填写表单( https://djisdksupport.zendesk.com/hc/zh-cn/requests/new )向我们反馈问题。或者您也可以在论坛发帖,与其它开发者交流。论坛链接:https://djisdksupport.zendesk.com/hc/zh-cn/community/topics

Dear developer, thank you for contacting DJI. Since github is not our main consultation channel, your questions may not be followed up in time. We recommend that you fill in the form (https://djisdksupport.zendesk.com/hc/en-us/requests/new) to report problems to us. Or you can post in the forum to communicate with other developers. Forum link: https://djisdksupport.zendesk.com/hc/zh-cn/community/topics

°°°

muratatakashi commented 2 years ago

I have the same issue. I have confirmed it on my iPad Pro 11inch (3rd generation), but it happens 100% on the iPad Pro while it happens sometimes on the iPhone. So far, I've been able to work around it by launching the app and then connecting to the drone and controller, but I hope DJI can solve this issue.

Sorry for the machine translated English.

DJI-William commented 2 years ago

@muratatakashi Please tell me how to reproduce this bug, thx.