Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Post updates lost when exiting very long post - WPAndroid #3177

Open
cameronvoell opened this issue Feb 18, 2021 · 5 comments
Open

Post updates lost when exiting very long post - WPAndroid #3177

cameronvoell opened this issue Feb 18, 2021 · 5 comments

Comments

@cameronvoell
Copy link
Contributor

Describe the bug
When editing a very large post, it is possible to edit the post, exit the editor, and have recent edits not be saved to the post as expected.

To Reproduce
Steps to reproduce the behavior:

  1. Load a large post in the editor. Example: https://upm59krakatit.wordpress.com/2021/02/08/long-post/
  2. Edit the title
  3. Wait 5 seconds
  4. Exit editor
  5. Notice changes are not shown in the post list

Expected behavior
Exiting the post should always save the latest changes in the post.

Screenshots
If applicable, add screenshots to help explain your problem.
save-problem-long-post

Smartphone (please complete the following information):

  • Device: Galaxy S10+
  • OS: [e.g. iOS 8.1, Android X] Android 11

Additional context
Add any other context about the problem here.

@cameronvoell cameronvoell added the [Type] Bug Something isn't working label Feb 18, 2021
@cameronvoell cameronvoell changed the title Post updates ost when exiting very long post - WPAndroid Post updates lost when exiting very long post - WPAndroid Feb 18, 2021
@mchowning
Copy link
Contributor

Thanks for investigating this and figuring out the steps to reproduce @cameronvoell ! 🙇

How consistently does this bug occur?

Based on the gif, it looks like the "fallback save" is being triggered when you exit the editor, but it is not actually saving the latest content for some reason. Is that your understanding?

Steps to reproduce the behavior:
...
3. Wait 5 seconds

Does this mean that the bug only occurs if you wait 5 seconds 😱 , or is there a different reason for including that step?

@mchowning mchowning added this to Triage in Mobile Gutenberg via automation Feb 18, 2021
@cameronvoell
Copy link
Contributor Author

How consistently does this bug occur?
Based on the gif, it looks like the "fallback save" is being triggered when you exit the editor, but it is not actually saving the latest content for some reason. Is that your understanding?

From my testing so far, it looks like likelihood of save failure is a factor of post length, device performance, and how long you wait after the last edit. I'll add a comment here with some more data points to help us figure out how common this bug is.

Does this mean that the bug only occurs if you wait 5 seconds 😱 , or is there a different reason for including that step?

I added the 5 second wait to show that this should not be affected by autosaves that would be pending because of the 1/2 second WPAndroid save debouncer.

@mchowning mchowning moved this from Triage to Backlog (unscheduled/unassigned) in Mobile Gutenberg Feb 23, 2021
@mchowning
Copy link
Contributor

I'll mark this as a high priority now because it involves data loss. It might be enough of an edge case though that it can be treated as a medium. Basically, I don't feel super-strongly.

@cameronvoell
Copy link
Contributor Author

Noting that the steps in the description seem to reproducible just about 100% of the time on my Samsung Galaxy S10 running Android 11 with this 97k word post

If I drop down to a 24k word post, I was able to get it maybe 1/5 times, and never got it in a post with less words than that.

When I tried testing on my Pixel 3 emulator running API 28, I could get it to occur with the 24k words post fairly easily, about 1/2 times.

Also noting that most times when this issue occur we also send the event in Sentry detailed in this issue: wordpress-mobile/WordPress-Android#13003

@SiobhyB
Copy link
Contributor

SiobhyB commented Jan 8, 2024

I tested using the 97k sample post from this comment and am still able to replicate the original steps towards content loss.

Noting that ~November 2021, some updates were made to improve saving/syncing on Android, in WordPress/gutenberg#36072, wordpress-mobile/WordPress-Android#15509, and pb3aDo-18j-p2. Following that work, the Sentry tracking event we had in wordpress-mobile/WordPress-Android#13003 was removed.

I'm leaving the [Pri] High label, as this issue is leading to content loss, but acknowledge we'd likely need help from an Android developer to fix this. It also may be related to ongoing issues we have with long posts in general.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Mobile Gutenberg
  
Backlog (unscheduled/unassigned)
Development

No branches or pull requests

3 participants