App rejected because of external-accessory value in the UIBackgroundModes key - swift

I accidentally turn on External accessory option in background modes and send the build to app store connect and after that, I receive the message which I show in image below,
after I uncheck the option (image attached) and send new build, and again I received the same message, what can I do now?

First, verify that you've actually sent the build you meant to. You probably have, but it's easy sometimes to not build what you think you built. Go to Window>Organizer, find the archive that you sent, Show in Finder, Show Package Contents, and check the Info.plist.
If everything looks fine, click the "Submit an appeal" link that Apple gives you to explain the issue. That's why there's a link.

Related

Accessing the console data from an iPhone application

When my app crashes, I would like to save the latest console for debug purposes (especially to read system messages such as unrecognized selector)
Is it possible to access the console programatically?
UPDATE:
I've found the answer in the documentations: using STDERR_FILENO.
"Logs an error message to the Apple System Log facility (see man 3 asl). If the STDERR_FILENO file descriptor has been redirected away from the default or is going to a tty, it will also be written there."
It sounds like you want to change the destination for the standard output stream. I've never tried that in iOS, but I'd expect to be able to do that using freopen(). Here's a SO question that may help.
You'll also want to build some debug feature into your app that makes it easy to recover the output. You could post it to a web server, for example, or have the app e-mail it to you.
When your app crashes in a device, a crash log is saved. When you plug your device in, launch XCode, open the "Organizer" window and click on devices. Then look for your device on the left, and click on "crash logs." Together with the information from the .dSYM file that's generated when you build, you can often recover how and where your app crashed. If you really just want to save the information in the console window of XCode when you crash, just click inside the console window, hit Cmd-A (select all), and Cmd-C (copy), then paste into a text editor window.

Is this allowed in App Store?

I am making an app for some people and they want to instantly update the app whenever they want after first submission. The changes will be like color, fonts, background color, removing a tab from tabbar...
What I was thinking was, creating a plist with entries like color, font and etc for specific views. And everytime an app starts up, it connects to a server and download the plist (if it's updated) and then load it's views according to the plist.
So for example, say the user wants to change the font from Helvetica to Arial. In plist I would have a dictionary with key named "Font" and object is the font name...So I simply update the plist with the font name "Arial" now and next time the app starts up, the font will change.
I hope I made it clear what I am trying to do. Now my question is, is this kind of thing allowed in app store? In reality, I am trying to circumvent the update system of App Store, but just wondering if it's allowed or if someone had experience doing this.
Thanks.
Your app is allowed to do these kinds of things, but be careful that your clients don't get the wrong set of expectations. The review process is not there to stifle creativity and color changes, but to prevent malicious code from running. You're not circumventing anything by using a web server to control the appearance of your app. Consider many apps which take content from the internet. You are merely taking it a step further.
The iTunes App and the App Store app have recently added a "Purchased" view without any user having to download anything new. You should be fine doing the same.
Yes, downloading content is ok. Downloading code however is not. So if the changes are due to different content you should be fine.
While nobody really knows until Apple says yea or nay, there are a few assumptions I believe to be safe:
1) If you're updating executable code (complied binary or a scripting language) you will not be accepted, and if you make it in somehow they'll yank the app and kick you off when they find out.
2) If you're updating resources (content, colors, fonts, etc.) you are probably fine, but Apple may decide to reject you anyway. Have a good case to defend yourself with if that happens.
All those changes are ok with Apple and can be performed dynamically in response to an external trigger (eg. api).
You can do whatever you want as long as you don't attempt to download and run additional code. (if you don't know what his means then you're fine). :)

iPhone - detecting crashes, prompting user to send crash log

Are there any libraries out there that would allow end users to send crash reports to developers?
For example, a user is using my app. It crashes. On boot up, a library loads before everything else and notices there is a crash report and prompts the user to send the crash log to me.
Is this possible? I think the Facebook app does something like this.
Thanks!
You actually have access to crash logs in iTunes Connect. Log in, go to Manage your Applications, pick an app, "View Details", and you should see a "Crash Reports" link to the right of the details pane.
That said, Apple only refreshes these daily, and will only give you access to reports of the most common crashes. If you want finer control, or need the user to submit reports directly, try plcrashreporter. You could ask the user for a submission this way, or just go ahead and automatically send all reports to your server. From the plcrashreporter site:
Introduction
Plausile CrashReporter implements
in-process crash reporting on the
iPhone and Mac OS X. The following
features are supported:
Implemented as an in-process signal
handler. Does not interfer with
debugging in gdb.. Handles both
uncaught Objective-C exceptions and
fatal signals (SIGSEGV, SIGBUS, etc).
Full thread state for all active
threads (backtraces, register dumps)
is provided. If your application
crashes, a crash report will be
written. When the application is next
run, you may check for a pending crash
report, and submit the report to your
own HTTP server, send an e-mail, or
even introspect the report locally.
Another alternative is HopToad - they host the site that will accept the crash reports and notify you.
iOS 5 and later
Tapping Settings > General > About > Diagnostics & Usage will allow you to choose between Automatically Send and Don't Send.
iOS 4 and earlier
By default, opting in is a one-time decision. If you'd like to change your decision, you can reset warnings for your iOS 4 or earlier device so that you will be asked again.
How to reset warnings within iTunes
Connect your iPad, iPhone, or iPod touch to your PC or Mac.
Wait until your device has appeared on the left side of the iTunes window under Devices.
Right-click (Mac or PC) or Control-click (Mac) the icon for your device.
From the shortcut menu, choose Reset Warnings:
The next time you sync after resetting warnings, you should see:
To disagree and stop sending Apple diagnostic and usage information, click No Thanks.
If you don't see the window above
Disconnect your device from your computer.
Open an application on your device.
Press and hold the Sleep/Wake button until the red slider appears, and then press and hold the Home button until the application quits. If you're using iOS 2.x or earlier, press and hold the Home button until the application quits.
Connect your device and sync it with iTunes.
The option to agree or disagree to diagnostics collection should appear again.
Chearz;)
Another alternative that we have been using at my company is Crittercism - http://www.crittercism.com/. They have been very responsive to feature requests and have really helped us prioritize which issues to address.
Their SDK also has the functionality I set out to look for so long ago! :)

How to get iPhone crash log from customers?

Does anyone knows how to get crash logs from customers? Instead of manually asking them to sync and go to this directory and this directory and send it.
Is there any automatic way to do send a crash report to our server?
You can perform your own crash-logging with PLCrashReporter. Typically, you write the crash log to a file and then send it to a server the next time the app starts.
In order to prevent an infinite crash-reporting loop (there was one in an early version), you want to do things in a specific order:
Read the file to memory and delete it. (Hopefully this won't crash.)
Parse the crash report and send it to the server. (If it crashes now, the file has been deleted, so it shouldn't happen again.)
Finally, enable crash reporting (so if it crashes in steps 1 or 2, the crash isn't logged).
In any case, you should have a "Oops, it crashed! Do you want to send a crash report?" dialog. I think automatic crash-logging is permitted by the default EULA, but it doesn't hurt to be nice to your users.
If you're worried about losing reports forever if the user says "no", instead of deleting the report, you can do logrotate-style style renaming (i.e. rename report8 to report9, rename report7 to report8, ..., rename report to report0). Then have a "send last N crash reports" button (either set N=10 or count the number of reports), so even if they've accidentally disabled it (or they had no internet at the time), they can still send the report.
iOS 5 and later
Tapping Settings > General > About > Diagnostics & Usage will allow you to choose between Automatically Send and Don't Send.
iOS 4 and earlier
By default, opting in is a one-time decision. If you'd like to change your decision, you can reset warnings for your iOS 4 or earlier device so that you will be asked again.
How to reset warnings within iTunes
Connect your iPad, iPhone, or iPod touch to your PC or Mac.
Wait until your device has appeared on the left side of the iTunes window under Devices.
Right-click (Mac or PC) or Control-click (Mac) the icon for your device.
From the shortcut menu, choose Reset Warnings:
The next time you sync after resetting warnings, you should see:
To disagree and stop sending Apple diagnostic and usage information, click No Thanks.
If you don't see the window above
Disconnect your device from your computer.
Open an application on your device.
Press and hold the Sleep/Wake button until the red slider appears, and then press and hold the Home button until the application quits. If you're using iOS 2.x or earlier, press and hold the Home button until the application quits.
Connect your device and sync it with iTunes.
The option to agree or disagree to diagnostics collection should appear again.
Chearz;)
reference:
http://support.apple.com/kb/HT4305
In iTunes, with their device tethered, if the user control-clicks on the name for their device, they will be able to select "Reset Warnings". Afterwards, a dialog box will pop up when the user next Syncs their device asking if it's OK to send data to Apple. If they click OK, then iTunes will upload all the crash logs from their device to Apple's servers.
Afterwards, you should be able to find your crash logs in iTunes Connect, and download them yourself. New crash logs will appear if your app still has problems and the user Syncs again, all automagically.
If you are talking about normal AppStore sales, Crash Reports are available through iTunes Connect.
Just go to "Manage Your Applications" -> "Your Application" -> And click "View Details" with the version currently active in the AppStore.
You will then get the details of your application, including the crash reports that are send in by your customers.

Possible to alert server to iphone settings change?

I'm working on giving our users context-specific PUSH notification settings, similar to what Facebook has in their settings menu.
As far as I can tell though, there's no way to actually notify our server of these changes until the user actually launches the app.
Is this correct? Is there any mechanism provided for immediately alerting our servers to a settings change?
That's correct: you can't detect changes made in the settings app until the next time your app launches.
The closest option to what you're describing would be to put the settings in your app somewhere and notify the server from there.