NordicSemiconductor / IOS-nRF-Connect

Info page
https://nordicsemiconductor.github.io/IOS-nRF-Connect/
136 stars 32 forks source link

App crashes/restarts when rotating app on DFU screen #163

Open jmaha opened 1 month ago

jmaha commented 1 month ago

This bug has been present for a long time. I noticed it's still there in the latest release 2.7.7.

If I do these steps, the app will exhibit a strange almost-crash back to the Scanning screen with all filters reset:

dinesharjani commented 1 month ago

I'm very sorry you've been dealing with this issue for these past few months - I wish I'd known sooner. I'll do my best to get this resolved quickly.

Would it help as well if I allowed you to 'not see' the Preview graphic of the contents of your firmware, to give you more space to read the filename, etc?

jmaha commented 1 month ago

It would definitely be helpful to have some way to see the full filename. It used to be possible to long-press the filename and it would show the whole thing, but that went away in the last UI redesign.

dinesharjani commented 1 month ago

Hey @jmaha - I've been working on this today. I can't replicate your issue. Connecting to a Nordic DFU Service Device, opening DFU, selecting a firmware file, seeing the Preview, and then rotating multiple times - I found a bug that deselects the "Device Details" after two rotations and doesn't allow you to show Device Details again in Landscape for a big device like the iPhone XR, but I don't see the kind of behaviour you're describing. Could you send me some screenshots / more specific information about the device? iOS version you're running? Or perhaps even a video.

Sorry for the inconvenience.

jmaha commented 1 month ago

I'm on an iPhone 14 Pro running iOS 17.5.1.

Here's a video of the crash happening: https://youtube.com/shorts/e5ayAYfW6o4

jmaha commented 1 month ago

The filename of the OTA image is 49 characters. This image has both an application and bootloader -- it's an image based on the nRF5 SDK.

dinesharjani commented 1 month ago

Okay, this helps. I guess it might be that you left the filter open, I did not try this use case. It's also one of the iPhone(s) with the Capsule instead of the "Notch" (I call them Batman ears) which I don't have to test, but I'll see what I can do. Thanks!

dinesharjani commented 1 month ago

Just an update - I'm working as diligently as I can on the issue. Trying to find an accurate way to reproduce it, since I have a stack trace of it but it's triggered by system calls due to the rotation event, so I don't get a location on our code of where source of the issue is.

jmaha commented 1 month ago

I see. Let me know if I can help gather any information.

dinesharjani commented 1 month ago

Hello @jmaha - I made a lot of underlying changes to the app, since I can't actually reproduce the issue in any of my devices. I think it's likely the crash will still occur, but even if it does, please enable the "Send Feedback" option Apple provides when installing the new beta. Here's the link for you to test this out: https://testflight.apple.com/join/FwMQS8tH

jmaha commented 1 month ago

Hi @dinesharjani, I just installed the TestFlight version and indeed the app does still crash when I rotate after selecting a DFU image. I submitted beta feedback via the testing mechanism when it reported the crash. Hopefully the stack trace arrives shortly!

dinesharjani commented 1 month ago

Hi @jmaha - a crash on rotation was fixed. However, it did not match the reported stack trace. Still I'd appreciate if you could try it out again (you should get a TestFlight notification to update or open TestFlight and tap Update) and if it still happens, to please attach a video once again. Also, a couple of details if you could provide them: does this happen straight after application launch, or only after performing other operations such as DFU? Does it happen if the Scanner Filter is closed instead of open? Does it happen (the crash) if you rotate before selecting a DFU package and you're in a different tab?

Thanks.

jmaha commented 1 month ago

I just tested the updated app, and it still crashes the same way. I tested both with and without the scan filter. I submitted several crash reports/stack traces. Video:

https://youtube.com/shorts/F6tc115P9pQ?feature=share Crash with nRF Connect 2.7.8 build 83 youtube.com

On Aug 2, 2024, at 4:15 AM, Dinesh Harjani @.***> wrote:

Hi @jmaha https://github.com/jmaha - a crash on rotation was fixed. However, it did not match the reported stack trace. Still I'd appreciate if you could try it out again (you should get a TestFlight notification to update or open TestFlight and tap Update) and if it still happens, to please attach a video once again. Also, a couple of details if you could provide them: does this happen straight after application launch, or only after performing other operations such as DFU? Does it happen if the Scanner Filter is closed instead of open? Does it happen (the crash) if you rotate before selecting a DFU package and you're in a different tab?

Thanks.

— Reply to this email directly, view it on GitHub https://github.com/NordicSemiconductor/IOS-nRF-Connect/issues/163#issuecomment-2265140958, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFIEUSSQBBMTY6T6Y4NK6ITZPNS6NAVCNFSM6AAAAABK7IE56WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENRVGE2DAOJVHA. You are receiving this because you were mentioned.

dinesharjani commented 1 month ago

Okay. I'm going to try something out on Monday. Something tells me that'll be it, but let's keep our fingers crossed.

Thank you for your valuable time.

dinesharjani commented 1 month ago

Hey @jmaha - there's a new build, number 92, out. Please try it out when you can. Thanks.

jmaha commented 1 month ago

Hi Dinesh,

I just tried the new build and the DFU screen still crashes on rotation. However, I did notice that in portrait orientation the firmware image name now wraps to the next line, so I’m able to read the entire name, thus eliminating the need for rotation.

That said, I’m happy to continue to test this for you if you’re going to keep chasing this crash!

Best, Jason

On Aug 5, 2024, at 8:47 AM, Dinesh Harjani @.***> wrote:

Hey @jmaha https://github.com/jmaha - there's a new build, number 92, out. Please try it out when you can. Thanks.

— Reply to this email directly, view it on GitHub https://github.com/NordicSemiconductor/IOS-nRF-Connect/issues/163#issuecomment-2269387099, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFIEUSW2TCRQIEHRMRUWNDDZP6NC3AVCNFSM6AAAAABK7IE56WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENRZGM4DOMBZHE. You are receiving this because you were mentioned.

dinesharjani commented 4 weeks ago

Hi Jason,

We might have to give it a rest, yes. Anyway, there's a new update in TestFlight now. Could you try that anyway for me, please?

dinesharjani commented 1 week ago

Update: I replicated the crash.