What does CNError.Code.communicationError error mean? - ios

I can see this error on some users (very very little percent) when trying to load contacts. The error is standard CNError, but I can not find information about the reason of its occuring. May be somebody can help?

Interesting question! To be fair I am not sure if I know the answer, however I will try to explain my suspicions for the cause of this error.
Contacts framework does not lookup just the database existing in a device when an app asks for contact data it also searches for contacts in other sources too, like your iCloud account, and returns back to the app unified contacts that originate from various sources.
The nature of this process indicates to me that this error could be related to the internet connection of the access to the iCloud contacts.
Again this is just a speculation and I can't confirm it. Maybe it would be worth if you try this on your own to simulate the behaviour.

Related

iPhone contact details corrupted how can I fix them?

At some point I noticed I’m seeing vcard coding or something to that effect and a bunch of my iPhone contacts. Please look at the example is there any way to fix this without having to go into each individual contact and delete the tags etc. it looks to be some type of V card code reference.
As you can see in the attached image for Apple headquarters, there is corrupted data. This is happening in a lot of my contacts I am seeing things such as X-SOCIALPROFILE at the end of phone numbers, etc..
I have another client that is experiencing the same issue (both with phone number and country name fields). I am posting something to the Apple forum hoping that someone there has an answer.
I think I figured out the issue.
Adding my work email, I had accidentally checked sync contacts. It is Microsoft based so it corrupted a bunch of my contacts trying to pull vCard data etc.
Also, Facebook messenger was corrupting my contacts
I disabled both of these syncing features, on my Mac went into contacts and searched for “x”
I found a lot of things like X-social etc appended to phone numbers etc
Based on this search in contacts I has to manually cleanup about 30 contacts. After about 1 hour my phone was synced to the updated iCloud contacts and everything is good.
Bottom line. Choose one source of truth to sync your contacts like iCloud.
Don’t allow 3rd party apps to access your contacts.
If you need anymore information let me know

How to detect if user has turned off mobile data for specific iOS App

I've come across a scenario where I need to know if the user has turned off mobile data for the app I'm developing so I can display a warning saying: "You have turned off mobile data, data will be synced when you connect to wifi". I wanted to be clear that I only need the information about my own app, not others the user has installed.
The problem is, i only have a narrow lead on where to start. I've come across a post saying this is possible, but not how. The answer talks about a "telephony class" which will enable some way of accessing the data about the settings for mobile data of your app. I'm guessing this is a native iOS class.
Link to the article on SO can be found here - link to post
My question is, which class, if there even is one in swift, has such an api, that I can get this information?
I'm new in swift and therefore know little of native classes and permissions.
I can provide more information if needed. This was all I could think of.
PS. I'm not looking for the Reachability class where I can detect WWAN / WIFI connection, unless this has some capabilities I'm not aware of.
Kind regards Chris

App rejected due to an IPV6 Swift3 error. How do I fix it?

A few days ago, Apple rejected my app, indicating that it didn't have IPV6 support, however I don't need that support since my app does not require internet access.
I asked the following:
Hi, my app does not need any internet connection yet.
So, why it's required to have support to IPV6?
They said:
Thank you for your response and for your question. In order to bring your app into compliance with Guideline 2.1 it would be appropriate for your app not to crash when logging in.
end
So, why do I need that Support?
If is necessarily, how do I can do it?
Please I need help
Test your app extensively and fix the crash. Enter wrong values, don't enter anything at all, intentionally try to break your app and get it to crash. Then you will find your error and you can fix.
EDIT BASED ON COMMENT BELOW
"My app don`t need conect with external database, because I got the information inside" - in this case, no, you do not need to add IPv6 support because you are not communicating with the internet for logging in purposes.
You can keep the login given it is only going to be 2 people using the app, just resolve the crash when logging in.
To test, enter a variety of incorrect passwords and usernames to ensure that there is no crash on incorrect entries, and confirm that correct entries do not crash the app.
Original Answer
Apple indicated that because there is a login feature, they think it is trying to communicate with an external database (ie a database that is not on the device). If there is no external database, just fix the crash is what they are asking.
Based on your question, you have eluded to the app not communicating externally for logging in. While some may find this odd, it is not uncommon. An example for those wondering would be a childrens app for iPad. The iPad might be shared amongst several children and as such each child might complete different sections or features of the app so an account local to the device is a good idea if there is no cloud support.
If there is external communication, you need to handle the case for no internet access. The question has been answered extensively, however this was the first result I found:
Detect Internet Connection and display UIAlertview Swift 3
Update: Why do I need to Support the case for no internet connection?
A use case:
John has just downloaded your app. He has just walked through the steps to create an account, but he has accidentally set his device to Aeroplane Mode.
John hits the "Create Now" button but nothing is happening. There is no error or success alert appearing, the screen has not changed, he can't see a loading icon. John is confused and getting frustrated because he's certain that he has completed everything in the form.
John doesn't understand that he needs internet connectivity to successfully submit a request to create an account. John decides to delete your app from his device and leaves a bad review.
John really could have used an alert saying "You need internet connection to sign up to this app. Please check you are connected and try again". This would have made John a whole lot happier and he probably would have continued to use your app with all of it's amazing features.
More information can be found in the guidelines that Apple mentioned, and further to this, the Apple Design Principles Guide is an invaluable resource.
I hope this makes sense.

My iOS app does not appear on Firebase dashboard

My app is live on the App Store and there are no crashes on the front end however when I log in to Firebase I cannot find it on the dashboard. I tried copy & pasting the database URL but I got the message saying that there was an error making the request and that I should try again later. Has anyone else encountered this issue and could advise me on who to contact to resolve it?
According to the Firebase Status Dashboard, there should be no issues with the Realtime Database at the moment.
Assuming that your app was associated with your Firebase account previously and just suddenly disappeared, I have not heard of/ encountered anything similar in the past.
One thing to try is to make sure you are logged into the correct account and have selected the correct project.
Since accessing the database directly through its URL says to try again later, this might be a temporary problem that is resolved shortly.
However to make sure, your best option at this point is probably to reach out to Firebase support directly using this form (requires sign-in).

Facebook: "URL could not be liked because it has been blocked" error in iOS app

I'm working on an iOS app that allows the user to like a Facebook page within the app. I've implemented this using FacebookLikeView. During the course of testing this functionality, I've liked and unliked the same page multiple times. Unfortunately, this seems to have triggered Facebook's spam detection. Now, when trying to like a page using the like button displayed by FacebookLikeView, the following error is presented: "URL could not be liked because it has been blocked".
Based on reports of the same problem found by searching the web, I've filled out this form to request that Facebook remove the block. However, I've received no response from them. I'm not sure how to proceed. Has anyone else run into this issue and successfully solved it?
With billions of pieces of content being shared on Facebook every month and bad actors constantly targeting the people who use Facebook, preventing spam isn't easy. Just as a community relies on its citizens to report crime, we rely on you to let us know when you encounter spam, which can be anything from a friend request sent by someone you don't know to a message that includes a link to a malicious website.
From : Explaining Facebook Spam Detection
This is no answer and what Donn Lee said is maybe the best answer.
My best guess at this is to send them lot information regarding you testing the app rather than abusing the system. You could try screenshots, contact info and explain what you are testing it for.
Try : Facebook Help Center
Developer Help : Rate Limits, Restrictions and Disables
Try filing a bug on the Facebook Developers Bugreporter.
If it's been a week and the site is still blocked, submit your site on this form.
if it comes down to no other option, there is also unrelated contact info on Facebook Newsroom, including the e-mail address press#fb.com.

Resources