Signal-Android icon indicating copy to clipboard operation
Signal-Android copied to clipboard

Message draft can get lost

Open cascheberg opened this issue 9 years ago • 2 comments

I have:

  • [x] searched open and closed issues for duplicates
  • [x] read https://github.com/WhisperSystems/Signal-Android/wiki/Submitting-useful-bug-reports

Bug description

A drafted message can get lost when you (mistakenly) open a conversation that has a drafted message and (therefore) go back to the conversation list immediately.

There is a quite noticeable lag until the message draft is displayed in the text input field. The bug occurs if you leave the conversation before the draft has been loaded.

Steps to reproduce

  • Add a message draft to a conversation
  • Open that conversation from conversation list
  • Immediately tap back button to go back to conversation list

Actual result: Message draft has been deleted Expected result: Message draft should be kept

Device info

Device: Nexus 4 Android version: stock Android 5.1.1 Signal version: 3.29.2

cascheberg avatar Feb 11 '17 07:02 cascheberg

I've tested this issue on several devices (4.4.4 & 6.0.1), also with different Signal versions (3.27.1, 3.28.4 & 3.29.2), and can confirm the bug on the latest Signal version (3.29.2). But it only appears if the "Video calling beta" is enabled. If this option is dissabled, the lag is not noticeable or even absent, like on older Signal versions.

Shenkaa avatar Feb 12 '17 13:02 Shenkaa

Great catch! The reason for the lag in ConversationActivity is the AsyncTask in initializeBetaCalling blocking the AsyncTask in initializeDraftFromDatabase.

cascheberg avatar Feb 12 '17 17:02 cascheberg