Troubleshooting involves many aspects of the system. The iOS SDK provides tools for troubleshooting and debugging problems.

Console messages

When you set the TLF_DEBUG environment variable to a non-zero value, the iOS SDK creates console messages with NSLog showing when it logs and transmits data.

Note: Support for the TLF_DEBUG environment variable and console messages is available for beta testing, and is not necessarily a part of the final release. The message format is subject to change.

Types of console messages

When you set the TLF_DEBUG environment variable to 1, the iOS SDK creates console messages with NSLog showing when it logs and transmits data. You can set this variable in the Build Arguments panel of your project's Scheme.

Sending messages to the console slows down your application, but shows you:

  • User actions and how they are being logged.
  • Server posts, both when they are being packaged and when they are finally sent.
  • Server responses so you can see that logging framework data is being received by your target page.

Tools for debugging

To help debug problems that are found during testing, you use the TLF_DEBUG environment variable and logger view.

Note: Support for the TLF_DEBUG environment variable and logger view is available for beta testing. They are not necessarily a part of the final release. The message formats are subject to change.


Runtime information

To find runtime information, you can check the current version of the iOS SDK and whether the iOS SDK is initialized at runtime.

frameworkVersion

Returns the version string for the iOS SDK that you are running.

– (NSString *)frameworkVersion

Returns the framework version string.

Declared in TLFApplicationHelper.h.

isTLFEnabled

Checks if the Tealeaf iOS SDK is enabled.

– (BOOL)isTLFEnabled

Returns YES if the iOS SDK is enabled, NO otherwise.

Declared in TLFApplicationHelper.h.


Crashes

During normal operations, accumulated events are written to a local file on the iOS device. If a power failure occurs while some events are contained in the file, the iOS SDK posts the contents of the file on restart of the application.

  • If the local file contains no data, nothing is done on restart.
  • If the file is corrupted, an error is logged on restart.

Known issues

Issue: UIPickerView- App crash when running Tealeaf SDK version 10.2.0.175 (and below)

Implementation of the pickerView:titleForRow:forComponent: method is mandatory when using the PickerView class, regardless if the viewForRow: method is implemented. Confirm that the pickerView:titleForRow:forComponent: method is implemented. For instrumentation, see the sample code at https://github.com/ibm-watson-cxa/iOSControls-SampleApp-iOS-ObjC/blob/master/iOSControls/PickersViewController.m


Join The Discussion

Your email address will not be published. Required fields are marked *