App icon indicating copy to clipboard operation
App copied to clipboard

[$1000] IOS - App freezes when user uploaded messages and image while offline

Open kbecciv opened this issue 2 years ago β€’ 38 comments

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Action Performed:

  1. Open the App
  2. Log in with any account
  3. Disable the internet connection in the device
  4. Navigate to a chat write something in the compose box
  5. Add attachment to a chat while there is text content in the composer
  6. Enable the internet connection

Expected Result:

After uploading a photo and writing a message, the conversation should scroll when user back online

Actual Result:

App freezes when user uploaded messages and image while offline

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • [ ] Android / native
  • [ ] Android / Chrome
  • [x] iOS / native
  • [ ] iOS / Safari
  • [ ] MacOS / Chrome / Safari
  • [ ] MacOS / Desktop

Version Number: 1.2.90.4

Reproducible in staging?: Yes

Reproducible in production?: yes

If this was caught during regression testing, add the test name, ID and link from TestRail:

Email or phone of affected tester (no customers):

Logs: https://stackoverflow.com/c/expensify/questions/4856

Notes/Photos/Videos: Any additional supporting documentation

https://user-images.githubusercontent.com/93399543/228068017-d479bb58-212b-43af-8553-979b9235d77a.mp4

Expensify/Expensify Issue URL:

Issue reported by: Applause - Internal Team

Slack conversation:

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01907c5dc79c397c99
  • Upwork Job ID: 1640583066029977600
  • Last Price Increase: 2023-03-28

kbecciv avatar Mar 27 '23 21:03 kbecciv

Triggered auto assignment to @jliexpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

MelvinBot avatar Mar 27 '23 21:03 MelvinBot

Bug0 Triage Checklist (Main S/O)

  • [x] This "bug" occurs on a supported platform (ensure Platforms in OP are βœ…)
  • [x] This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • [x] This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • [x] This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • [x] I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

MelvinBot avatar Mar 27 '23 21:03 MelvinBot

Reproduced this on iPhone 13.

kadiealexander avatar Mar 28 '23 05:03 kadiealexander

Job added to Upwork: https://www.upwork.com/jobs/~01907c5dc79c397c99

MelvinBot avatar Mar 28 '23 05:03 MelvinBot

Current assignee @kadiealexander is eligible for the External assigner, not assigning anyone new.

MelvinBot avatar Mar 28 '23 05:03 MelvinBot

Triggered auto assignment to Contributor-plus team member for initial proposal review - @eVoloshchak (External)

MelvinBot avatar Mar 28 '23 05:03 MelvinBot

Triggered auto assignment to @danieldoglas (External), see https://stackoverflow.com/c/expensify/questions/7972 for more details.

MelvinBot avatar Mar 28 '23 05:03 MelvinBot

I can take it :)

koko57 avatar Mar 28 '23 10:03 koko57

πŸ“£ @koko57 You have been assigned to this job by @mountiny! Please apply to this job in Upwork and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review πŸ§‘β€πŸ’» Keep in mind: Code of Conduct | Contributing πŸ“–

MelvinBot avatar Mar 28 '23 10:03 MelvinBot

Not overdue!

kadiealexander avatar Mar 30 '23 23:03 kadiealexander

is this bounty available?

KartikDevelopment avatar Mar 31 '23 19:03 KartikDevelopment

@danieldoglas, @eVoloshchak, @koko57, @kadiealexander Whoops! This issue is 2 days overdue. Let's get this updated quick!

MelvinBot avatar Apr 03 '23 09:04 MelvinBot

I cannot recreate this issue on v1.2.92-2

koko57 avatar Apr 03 '23 11:04 koko57

@kbecciv can you please retest?

danieldoglas avatar Apr 03 '23 11:04 danieldoglas

I was able to reproduce this on v1.2.94-3 from the AppStore

eVoloshchak avatar Apr 05 '23 16:04 eVoloshchak

@eVoloshchak yeah I updated the app and tested once again - it is reproducible indeed. I will investigate the issue. What's more it happens also when you don't turn off the internet connection.

koko57 avatar Apr 05 '23 17:04 koko57

Investigating the issue

koko57 avatar Apr 06 '23 11:04 koko57

Still investigating - I cannot reproduce it locally on a device but I've noticed that in the app from the AppStore the keyboard is dismissed and I guess that this may be causing the issue.

koko57 avatar Apr 07 '23 14:04 koko57

@danieldoglas @eVoloshchak @koko57 @kadiealexander this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

MelvinBot avatar Apr 10 '23 09:04 MelvinBot

@danieldoglas @eVoloshchak @koko57 @kadiealexander this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!

MelvinBot avatar Apr 10 '23 10:04 MelvinBot

@koko57, I was able to reproduce this even without turning on the internet back again. It's also not reproducible when there is no text in the composer, so you might be right about the keyboard causing this.

https://user-images.githubusercontent.com/9059945/230888274-2ba8c1c1-6282-4913-8e72-ad488a99d2bb.MP4

eVoloshchak avatar Apr 10 '23 10:04 eVoloshchak

Thanks @eVoloshchak 😊 I need to add some changes to my PR for other issue, I'll be investigating the keyboard behaviour right after

koko57 avatar Apr 11 '23 10:04 koko57

Still investigating. Strangely this.updateComment('') in prepareCommentAndResetComposer() in ReportActionCompose fixes the issue - keyboard is not dismissed, the screen is responsive and scrollable, the input is focused but the text sent with the attachment is not cleared.

koko57 avatar Apr 12 '23 16:04 koko57

@danieldoglas @eVoloshchak @koko57 @kadiealexander this issue is now 3 weeks old. There is one more week left before this issue breaks WAQ and will need to go internal. What needs to happen to get a PR in review this week? Please create a thread in #expensify-open-source to discuss. Thanks!

MelvinBot avatar Apr 17 '23 10:04 MelvinBot

@koko57 how are we in this issue?

danieldoglas avatar Apr 17 '23 10:04 danieldoglas

@danieldoglas Still working on the proposal. I've found a workaround that fixes the issue - wrapping this.updateComment('') (in prepareCommentAndResetComposer() in ReportActionCompose) in InteractionManager.runAfterInteractions. I've also found out that it happens only when the Composer is multiline - when this prop is removed the issue doesn't occur.

koko57 avatar Apr 17 '23 10:04 koko57

I'd thought that it's a keyboard/KeyboardAvoidingView issue but I've finally found out the real culprit - RCTModalHostViewController is not unmounting and overlaps the screen making it unresponsive (but the attachments are loading correctly) - there are several issues related to the RN modal bug, several from the Expensify/App repo https://github.com/Expensify/App/issues/14848, https://github.com/Expensify/App/issues/7768, https://github.com/Expensify/App/issues/2719, the others from RN https://github.com/facebook/react-native/issues/32329, https://github.com/react-native-modal/react-native-modal/issues/484, https://github.com/react-native-modal/react-native-modal/issues/534. Although some of them are closed the issue with modal dismisal seems to still be waiting for a better solution

koko57 avatar Apr 18 '23 16:04 koko57

@koko57 do you think we can work on an upstream fix for this?

danieldoglas avatar Apr 18 '23 16:04 danieldoglas

@danieldoglas Would be ideal, but it seems to be a tough one. I'm still investigating what can be done here. Regarding the issue - for now the only working workaround solution (not ideal though) is InteractionManager.runAfterInteractions / setTimeout like in the previous issues.

koko57 avatar Apr 18 '23 17:04 koko57

@danieldoglas As I dug deeper into this persisting RCTModalHostViewController issue I've found a hint that may finally lead me to finding the real cause of this issue. It probably won't require any change in RN. I need to test it thoroughly and hopefully tomorrow I'll be able to tell if it's working.

koko57 avatar Apr 19 '23 14:04 koko57