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

Import vCard from file crashes or returns "Empty/invalid file" #53

Closed
justjulian opened this issue Dec 27, 2018 · 6 comments
Closed

Import vCard from file crashes or returns "Empty/invalid file" #53

justjulian opened this issue Dec 27, 2018 · 6 comments

Comments

@justjulian
Copy link

justjulian commented Dec 27, 2018

I have a vCard stored locally in my phone that I would like to import, it just contains one contact. I tried importing it with the stock contact app to a etesync address book which worked. Importing this same file by using the etesync app itself however does not work.
From within an address book I tap Import --> From File, I get the following options

2018-12-27 12 43 54

I tried the following options and include the log files for it:

[1] Huawei CAN-L11
etesync-4807-20181227-124727-huaweicanl11.txt
[2] Internal Storage
etesync-4562-20181227-124531-internalstorage.txt
[3] Files
etesync-4688-20181227-124634-files.txt
[4] Total Commander
etesync-4231-20181227-124306-totalcommander.txt

Note that with [2] it is using the Stackfield app on my phone to access the content which I think is pretty weird.
Options [1] and [4] return an error in the app: Empty/invalid file
Options [2] and [3] result in a stuck app with the following screen

2018-12-27 12 39 56

As mentioned, this vCard is valid and could be imported with the stock contact app. Therefore I would expect this should also work from within etesync.

Android version 7.0
EMUI version 5.0.3
Model Number Huawei CAN-L11

@justjulian justjulian changed the title Import vCard from file crashes or returns Empty/invalid file Import vCard from file crashes or returns "Empty/invalid file" Dec 27, 2018
@justjulian
Copy link
Author

I deleted the address book and tried the import on a fresh one. That worked. Can be closed if no one thinks that it should be analyzed further.

@tasn
Copy link
Member

tasn commented Jan 1, 2019

Sorry I didn't get to it before. I think it's still worth investigating, or at least I should try to reproduce it. It seems like EteSync wasn't able to access the file before, but is able to access it now? You can't reproduce it anymore, right?

@justjulian
Copy link
Author

Correct, I cannot reproduce it anymore.
Though, in the meantime I also upgraded from 0.22.3 to 0.22.4. Could be related.

@tasn
Copy link
Member

tasn commented Jan 2, 2019

Would you mind sending me the vcard (support@etesync.com) in question? Please feel free to filter out any information you deem private, e.g. replace the name from Tom to -> Aaa. Just please keep the character count similar (i.e replace one letter for one), if there are unicode chars, maintain them as much as possible, and etc. Same goes for phone numbers.

This could help a lot.

As for the upgrade: there has been a tiny fix touching contacts that could be relevant if the contact has a group (sometimes called label) associated.

@justjulian
Copy link
Author

Hi Tom and sorry for the late reply. I'm afraid that this would take too much time to replace all private information. It's over 100 contacts with emails, phone numbers, and addresses. The file contains 1184 lines with a character count of 23922. A typical example looks like this:

BEGIN:VCARD
VERSION:4.0
FN:FirstName LastName
N:LastName;FirstName;;Dr.;
CATEGORIES:Misc
GENDER:F
TEL;PREF=1;TYPE=home:+4111111111111
TEL;PREF=2;TYPE=work:+4111111111112
EMAIL;PREF=1;TYPE=home:name@example.com
EMAIL;PREF=2;TYPE=home:name@otherexample.com
ADR;PREF=1;TYPE=home:;;Street number;city;;zip;country
BDAY:1960-01-01
END:VCARD

I would recommend to extend the error message in case this happens again (as I cannot reproduce it anymore) and then if it happens again we have hopefully more information on this.

@tasn
Copy link
Member

tasn commented Jan 7, 2019

I improved some of the import code and the new version is just out. Since you also can't reproduce it, I'll close it until you do, and then I can send you a version with more debug info.

@tasn tasn closed this as completed Jan 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants