Saving all media results in error
- [x] I have searched open and closed issues for duplicates
- [x] I am submitting a bug report for existing functionality that does not work as intended
- [x] I have read https://github.com/signalapp/Signal-Android/wiki/Submitting-useful-bug-reports
- [x] This isn't a feature request or a discussion topic
Bug description
When I select all media and click Save, the media is not saved, but I get an error notification
Steps to reproduce
- Click Manage storage
- Click REVIEW STORAGE
- Click Media
- Long press the first item, so it gets selected
- Click Select all
- Click Save
Actual result: Message: Error while saving attachments to storage Expected result: All media saved.
I guess some attachments (media) are missing, causing the export to stop. It would be useful to have some feedback about which files cause the issue, with an option to delete them. Now I have to manually try to find which file is causing the issue.
Device info
Manufacturer : HMD Global Model : Nokia 4.2 Product : Panther_00EEA Screen : 720x1370, xhdpi (300), 60.00 hz Font Scale : 1.0 Animation Scale : 1.0 Android : 11, API 30 (00EEA_3_24B, 00EEA_3_240_SP02) (see debug log for full details)
Link to debug log
https://debuglogs.org/android/6.44.3/6910d7daa4299c7ad3002f0ce754a39034be066fa397efe828a422dd49cefcd8
There are multiple stack traces in the debug log. This is just one snippet:
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: Missing attachment for size calculation
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: java.io.FileNotFoundException: /data/user/0/org.thoughtcrime.securesms/app_parts/part4252733374678444408.mms: open failed: ENOENT (No such file or directory)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at libcore.io.IoBridge.open(IoBridge.java:492)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at java.io.FileInputStream.<init>(FileInputStream.java:160)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.crypto.ModernDecryptingPartInputStream.createFor(ModernDecryptingPartInputStream.java:30)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.openAttachmentStream(FullBackupExporter.java:524)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.calculateVeryOldStreamLength(FullBackupExporter.java:504)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.exportAttachment(FullBackupExporter.java:459)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.lambda$internalExport$5(FullBackupExporter.java:170)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.$r8$lambda$mogkeV-f4Nl33FkF1qr_gAHVwK8(FullBackupExporter.java:0)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter$$ExternalSyntheticLambda9.postProcess(R8$$SyntheticClass:0)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.exportTable(FullBackupExporter.java:431)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.internalExport(FullBackupExporter.java:170)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.backup.FullBackupExporter.export(FullBackupExporter.java:120)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.jobs.LocalBackupJobApi29.onRun(LocalBackupJobApi29.java:142)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.jobs.BaseJob.run(BaseJob.java:31)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.jobmanager.JobRunner.run(JobRunner.java:86)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at org.thoughtcrime.securesms.jobmanager.JobRunner.run(JobRunner.java:49)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: Caused by: android.system.ErrnoException: open failed: ENOENT (No such file or directory)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at libcore.io.Linux.open(Native Method)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at libcore.io.ForwardingOs.open(ForwardingOs.java:166)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at libcore.io.BlockGuardOs.open(BlockGuardOs.java:254)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at libcore.io.ForwardingOs.open(ForwardingOs.java:166)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at android.app.ActivityThread$AndroidOs.open(ActivityThread.java:7583)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: at libcore.io.IoBridge.open(IoBridge.java:478)
[6.43.2] [23807] 2024-01-25 01:26:45.487 GMT+01:00 W FullBackupExporter: ... 15 more
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been closed due to inactivity.
Sorry, I missed the stale notification. I just tried again, and this issue is not fixed. Could you please reopen this issue.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
I tested this again today.
I updated the initial procedure above slightly to match the current Signal version.
I followed the update procedure as described above.
After clicking save, I saw a spinner, that was there for a little more than an hour (as side note: having a bit more detailed progress information than just the spinner would be helpful, I had no idea of how long I had to wait). I did not see when the process finished. But there were no clear remaining error or warning messages. However, the files were not saved.
There were 6951 files selected, totaling 4.46 GB.
Here is a debug log (I started the saving around 2025-04-11 10:05):
https://debuglogs.org/android/7.39.4/3812ddf81aae0794c52a9f21775dc131172adcb853ef4ea6983d721579a451f3
Note there are several stack traces, like:
[7.39.4] [8467 ] 2025-04-11 11:06:40.422 GMT+02:00 I DecryptableStreamLocalU: java.io.IOException: No stream for: AttachmentId::12011
and:
[7.39.4] [8504 ] 2025-04-11 10:08:14.860 GMT+02:00 W AttachmentTable: java.io.FileNotFoundException: /data/user/0/org.thoughtcrime.securesms/app_parts/part5550925960742247208.mms: open failed: ENOENT (No such file or directory)
Hi, we recently added some changes to the all media saving process such that if one file fails, it'll still go through with the others. Do you remember seeing a toast along the lines of "Media saved (x of y failed)"?
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been closed due to inactivity.