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

Corrupt Signal DB issue crashing App #11160

Open
4 tasks done
jonfen opened this issue Apr 2, 2021 · 14 comments
Open
4 tasks done

Corrupt Signal DB issue crashing App #11160

jonfen opened this issue Apr 2, 2021 · 14 comments

Comments

@jonfen
Copy link

jonfen commented Apr 2, 2021


Bug description

This morning I had a "XXX has joined signal message" for every signal user in my contacts, none of the conversations were there. I was able to mark all as read, but if I clicked on any one of them signal would crash. When someone would send a signal message it would say "Chat Session Refreshed", but I couldn't open up the chat, the app would crash if I tried. Signal was my default app, so to even receive an SMS I had to switch to Android Messages.

My solution was to uninstall signal, and not restore using a backup, so I started over. Besides losing everything, it works as expected now. Signal is the my default app again. Before going nuclear, I did attempt to backup the existing chats, from the fast speed to create and small size of this backup, it was clear that my original messages were already gone.

Does the underlying DB engine have a size limit I could have hit? I have been using the app for over half a decade and kept transferring messages from phone to phone.

Steps to reproduce

  • unknown

Actual result: Describe here what happens after you run the steps above (i.e. the buggy behaviour)
Expected result: Describe here what should happen after you run the steps above (i.e. what would be the correct behaviour)

Device info

I checked and didn't have any signal updates or OS updates happen for at least a week, I don't think that was the issue.
Device: Google Pixel 5
Android version: 11 (build RQ2A.210305.006)
Signal version: 5.5.5

Link to debug log

I didn't get this in time.

@jonfen jonfen changed the title Corrupt Signal DB issue Corrupt Signal DB issue crashing App Apr 2, 2021
@bkurdali
Copy link

bkurdali commented Apr 2, 2021

I had the same issue - my fear is that it's because I'm low on space (also a long time signal user) as my phone only has 32G of storage (it has an SD card but afaik signal can't use that except for backups) and maybe something temporarily fills up the main storage and signal corrupts.
It hadn't occured to me that the DB itself might have a size limit.

@bakoorahnin
Copy link

bakoorahnin commented Apr 2, 2021

try with app.asana.com

@jonfen
Copy link
Author

jonfen commented Apr 3, 2021

try with app.asana.com

While it does have its place, using asana defeats the point of privacy.

@nh2
Copy link
Contributor

nh2 commented Apr 17, 2021

I can confirm this issue exactly, also on Android:

  • The problem started one day with "... has joined Signal". (It is possible that the phone was low on storage on that day.)
  • Subsequently I got this stack trace upon startup 4 out of 5 times, and 19 out of 20 times when trying to open any conversation: Signal crashes at start with "MissingRecipientException: Failed to find recipient with ID: null" #10868 (comment)
  • This instant crash made Signal unusable for the last few months. I could not read many new messages.
  • Today I decided to do a Signal backup. The app used 2 GB storage according to the Android device manager. I made sure that 3 GB are free. The backup procedure ran through within 1 second, and the created backup file is only 1 MB in size.
  • Reinstalling Signal and trying to import that backup has no effect. It immediately brings me to the "Enter your phone number to get started" screen, as if I had imported nothing. Subsequently, there no conversations restored.
  • There is no error mesage about neither the backup failing, nor the restore failing.

This bug effectively deleted 8 years of Signal conversations from my phone.

I do have backups, but they are multiple months old. There's also some business correspondence SMS received ealier today that is now permanently lost, requiring me to contact those people and tell them "sorry, can you write that again, Signal lost the data", which isn't great.

@nh2
Copy link
Contributor

nh2 commented Apr 17, 2021

Does the underlying DB engine have a size limit I could have hit?

Completely random guess that tends to hit the mark in a large fraction of cases in my last 14 years of software development:

Android claimed the Signal app used roughly 2.1 GiB of storage. 2.1 GiB is suspiciously close to the maximum 32-bit int value.

@nkosi23
Copy link

nkosi23 commented Apr 17, 2021

Just to help narrow down the actual issue: My signal is using 3.08Gb of storage on Android 9 and I haven't faced this issue, everything is still working great (installed in 2018 - did not import backups at the time)

@nkosi23
Copy link

nkosi23 commented Apr 17, 2021

However I do have over 6gb of free space remaining. It looks like the db engine does not have a storage limit, but maybe the issue is purely related to low free space on the device.

@greysonp
Copy link
Contributor

greysonp commented Apr 17, 2021

Does the underlying DB engine have a size limit I could have hit?

2.1 GiB is suspiciously close to the maximum 32-bit int value.

I would not be concerned about that. The simple answer is 'no', and the complex answer is 'it depends, but likely so high that it isn't an issue here'. Attachments are stored separately and make up the vast majority of your install size. My personal Signal install is ~13GB, but my database is only ~140MB of that.

I can't say much about what happened or why without any logs of any sort. If anybody has experienced anything similar and is able to get logs via ADB or something, it'd be greatly appreciated :)

@williamscales
Copy link

williamscales commented Apr 17, 2021

I am also having this or a similar issue. I'm not able to open Signal, it immediately crashes.

I tried re-installing and restoring my database but it never completes.

@nh2
Copy link
Contributor

nh2 commented May 15, 2021

I can't say much about what happened or why without any logs of any sort. If anybody has experienced anything similar and is able to get logs via ADB or something, it'd be greatly appreciated :)

I supposed you'd need ADB logs of the moment it happens, right?

This appears difficult to do, given that the corruption itself happens in an instant, as a normal user you don't see it coming, and when you notice that Signal continues to not work, you've already rebooted a couple of times.

@stale
Copy link

stale bot commented Jan 26, 2022

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the wontfix label Jan 26, 2022
@nh2
Copy link
Contributor

nh2 commented Jan 26, 2022

Is this still relevant? If so, what is blocking it?

Would be nice if a dev could take a look at it I guess, since DB corruptions usually don't disappear by themselves.

@stale stale bot removed the wontfix label Jan 26, 2022
@stale
Copy link

stale bot commented Mar 27, 2022

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the wontfix label Mar 27, 2022
@nh2
Copy link
Contributor

nh2 commented Mar 27, 2022

This bot is a really great way for humans to waste their time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants