tmo1 / sms-ie

SMS Import / Export is a simple Android app that imports and exports SMS and MMS messages, call logs, and contacts from and to JSON / NDJSON files.
GNU General Public License v3.0
319 stars 38 forks source link

Trouble importing messages #123

Closed fantasymeal closed 11 months ago

fantasymeal commented 11 months ago

Hello, previously I have used Silence 0.15.16, that contains 2899 SMS, and many MMS, on my phone (Samsung Galaxy A52s 5G, Android 13). However, I'm trying to switch over to the built-in Samsung Messages 14.1.30.21 app. So I installed SMS Import/Export (version 2.0.0-pre.2 from F-Droid), and the Export messages works but only 2391 SMS are exported. 2391 SMS is what I imported to the phone before I started to use Silence, so possibly Silence hide all new SMS.

However, when I put phone in flight mode, and make SMS Import/Export default app for SMS and then try the Import messages function and choose a zip file nothing happens, it just shows the text below but no error messages: 0 SMS(s) and 0 MMS(s) imported Elapsed time: 00:00

I have tried to import 3 different zip files without any success:

  1. File with 2391 SMS exported previously from SMS Import/Export.
  2. File with 2899 SMS converted from Silence with Python script https://github.com/tmo1/sms-ie/issues/121. I manually converted all emojis to not give error.
  3. File with 1 SMS manually edited from (1) above and later zipped in Fedora Linux.

(1) and (2) should possibly not be imported since they should already by in the SMS database, but I'm surprised that SMS Import/Export is done already after 00:00 seconds without even scanning through them. (3) should be imported since it is a new SMS not in database. I have also noticed that the number of tags differ between the default exported (1) and what is made in the Python script (2), but perhaps this shouldn't matter!? I have set language English (US) in Android with no success, in case SMS Import/Export or NDJSON is sensitive to European delimiters (semicolon instead of comma, comma instead of decimal period etc).

Am I making any obvious mistake? What am I missing?

tmo1 commented 11 months ago

previously I have used Silence 0.15.16, that contains 2899 SMS, and many MMS, on my phone (Samsung Galaxy A52s 5G, Android 13). However, I'm trying to switch over to the built-in Samsung Messages 14.1.30.21 app. So I installed SMS Import/Export (version 2.0.0-pre.2 from F-Droid), and the Export messages works but only 2391 SMS are exported. 2391 SMS is what I imported to the phone before I started to use Silence, so possibly Silence hide all new SMS.

I'm not sure how Silence works, but some message apps (e.g. Signal) don't store their messages in the standard system message database but rather in their own database. SMS I/E only exports messages in the system database, and not those in the databases of other apps, so if Silence is storing messages it sends and receives in its own database, then they won't be exported by SMS I/E.

Am I making any obvious mistake? What am I missing?

I don't see any mistake, and I have no idea why it isn't working for you. Can you post ZIP file #3 so I can test it and try to figure out what's wrong? You can sanitize / redact any personal information.

fantasymeal commented 11 months ago

Thanks for quick reply! Attached is messages.zip for #3.

tmo1 commented 11 months ago

Thanks! The file you attached imports fine here (with version 2.0.0). Can you verify that Settings / Debugging options / Process SMS messages is set on your device? If it is, can you please provide a logcat of an import that does not work?

fantasymeal commented 11 months ago

The option Process SMS messages is enabled. Here is a logcat from when I open the app (2023-08-29 21:48:45) and later try to import messages (2023-08-29 21:49:00). Now it is filtered for SMS I/E only, is this enough or do you need to see more details?

tmo1 commented 11 months ago

I'm more or less out of ideas. You can check whether the problem remains in the latest version (I just released v2.1.0); if it does, we'll have to try a version of the app with more robust debug logging. Better debug logging is something I should really implement anyway, and it shouldn't be too complicated to do, so I hope to have such a version out soon.

fantasymeal commented 11 months ago

I installed v2.1.0 and it worked like a charm. Many thanks for the help and a great app!

tmo1 commented 11 months ago

Great! I'm still puzzled by why the earlier version wasn't working, but I'm glad it's working now.