KonyOne Studio Troubleshooting Guide

KonyOne Platform Release 5.0

KonyOne Studio Troubleshooting Guide - Ver 5.0

Copyright © 2013 by Kony, Inc. All rights reserved. July, 2013 This document contains information proprietary to Kony, Inc., is bound by the Kony license agreements and may not be used except in the context of understanding the use and methods of Kony software without prior, express, written permission. Kony, KonyOne and Empowering Everywhere are trademarks of Kony, Inc. Microsoft, the Microsoft logo, Internet Explorer, Windows and Windows Vista are registered trademarks of Microsoft Corporation. Apple, the Apple logo, iTunes, iPhone, iPad, OS X, Objective-C, Safari and Xcode are registered trademarks of Apple, Inc.. Google, the Google logo, Android and the Android logo are registered trademarks of Google, Inc. Chrome is a trademark of Google, Inc. BlackBerry, PlayBook, Research in Motion, and RIM are registered trademarks of BlackBerry. All other terms, trademarks or service marks mentioned in this document have been capitalized and are to be considered the property of their respective owners.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 2 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Revision History Date

Document Version

Description of Modifications/Release

08/31/2011

1.0

New document released

12/14/2012

2.0

Updated solutions for Emulator and Build errors

11/1/2013

3.0

Updated solutions for iPad issue and Map errors

4/4/2013

4.0

Updated Blackberry query regarding Preview

06/11/2013

5.0

Updated Symbolicating iPhone crash reports

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 3 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

1. Troubleshooting This chapter explains how to troubleshoot specific issues you may encounter while developing application using KonyOne Studio.

1.1 Eclipse This section lists a few troubleshooting tips to resolve problems that you may encounter with Eclipse. Eclipse prompts for a License file every time it is launched in Windows Parallels on a MAC machine. Cause Windows Parallel is sharing the MAC User Profile. Solution Create a user profile for Window Parallels. 1. Navigate to Parallels Desktop. 2. Go to Virtual Machine -> configure. 3. Click options tab. 4. Select shared profile in the left pane and deselect Enable the shared profile. 5. Restart Windows Parallels.

Eclipse crashes when Lua Editor is opened. Cause

org.keplerproject.ldt.win32 plug-in is missing or Eclipse did not read this plug-in correctly. Solution 1. Check if this plug-in is available in the plugins/dropins folder of the Eclipse. Check in plugins folder if you have installed Eclipse using automatic update feature. If you have installed Eclipse using the manual procedure, check in the dropins folder. 2. If this plug-in already exists, close Eclipse and re-launch Eclipse from the Command Prompt:

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 4 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Navigate to the folder where you have installed Eclipse and run the following command: eclipse.exe -clean 3. Remove all the Lua plug-ins. Download the Lua plug-ins to the appropriate folder and restart Eclipse with the following command from the Command Prompt: eclipse.exe -clean

Eclipse does not detect Kony plug-ins. Cause Plug-ins were not downloaded properly. Solution 1. Close Eclipse and re-launch it from Command prompt. eclipse.exe -clean 2. Navigate to the folder where you have installed Eclipse and run the following command: 3. Delete all the Kony plug-ins. Download the Kony plug-ins to the appropriate folder and restart Eclipse with the following command from the Command Prompt: eclipse.exe -clean 4. Close Eclipse and navigate to workspace. 5. Take a backup of the file com.pat.tool.keditor.prefs from

.metadata\.plugins\org.eclipse.core.runtime\.settings folder within workspace and delete .metadata folder. 6. Restore the backed-up file com.pat.tool.keditor.prefs file to its location .metadata\.plugins\ org.eclipse.core.runtime\.settings\. 7. Launch Eclipse. Important! If you do not take a backup of the file com.pat.tool.keditor.prefs, all your preferences like emulator path, server ports, and so on are lost when you delete the .metadata folder.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 5 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Eclipse throws OutOfMemory error. Cause Insufficient memory allocated to Eclipse. Solution 1. Open the eclipse.ini file located in the Eclipse installation folder. 2. Edit the following line: -Xmxm For example, -Xmx512m indicates that 512 MB must be allocated to Eclipse. If such a flag does not exist, add it in the eclipse.ini file. Eclipse throws OutOfMemoryError:PermGen space error. Cause Insufficient memory allocated to Eclipse. Solution 1. Open the eclipse.ini file located in the Eclipse installation folder. 2. Edit the following line: -XX:MaxPermSize=m For example, -XX:MaxPermSize=128m indicates that 128 MB must be allocated to Eclipse. If such a flag does not exist, add it in the eclipse.ini file. Eclipse displays "Improper Workspace" error. Cause When you attempt to launch an emulator multiple times, this error comes up, because the emulators try to access the same workspace. Solution 1. Close the error window and any other related window.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 6 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

2. Restart Eclipse.

Eclipse is shutting down after building for Blackberry using the below configuration in eclipse.ini file. -startup plugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar --launcher.library plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.2.R36x_ v20101222 -product org.eclipse.epp.package.jee.product --launcher.defaultAction openFile --launcher.XXMaxPermSize 768M -showsplash org.eclipse.platform --launcher.XXMaxPermSize 768m --launcher.defaultAction openFile -vmargs -Dosgi.requiredJavaVersion=1.5 -Xms768m -Xmx768m Cause High values were set for memory settings (-xms and -xmx). Eclipse will shutdown when the memory consumption raises significantly and runs out of memory. Solution Memory parameters should be set based on the system configuration. Below are the recommended values to be set based on your system configuration: -xms - between 128m - 256m -xmx - between 512m - 1024m -Xms256m -Xmx512m

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 7 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

2. KonyOne Studio This section explains the cause and solution of a few problems that you may encounter while working with KonyOne Studio. "Kony" not available in Open Perspective window. Cause SOAP UI plug-in is not installed. Solution 1. Download the com.pat.soapui_x.x.x plug-in to plugins/dropins folder of Eclipse. 2. Restart Eclipse.

Some of the default KonyOne Studio views do not appear. Cause Views were closed. Solution l

Reset the Kony Perspective using Window -> Reset Perspective.

Lua methods do not appear in the Custom Libraries window in earlier versions of KonyOne Studio (prior to 3.0). Cause The Lua methods use Lua Closure or Lua Tables as input or output parameters. Lua Closure and Lua Table are not supported in earlier versions of KonyOne Studio (prior to 3.0). Solution 1. Launch the Custom Libraries window (in KonyOne Studio version 3.0) and remove/replace all the Lua Closures or Lua Tables with other suitable datatypes. 2. Open the project in earlier version of KonyOne Studio and launch the Custom Libraries window to see a list of the Lua methods.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 8 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Images copied to the resources folder through Windows Explorer or from the Navigator View do not appear in the Image Browser when you want to use them in the application. Cause Image does not conform to the naming convention or the resources folder was not refreshed. Solution 1. Right-click the resources folder and select New Resource option for adding new images (following the naming convention) to the application. For more information about naming the images, see the Naming Conventions section in KonyOne Studio User Guide. 2. Refresh the resources folder.

Unable to set Margins/Paddings or any other tablet related properties for a form designed for Tablet. Cause Form designed for mobile was copied manually to the tablet folder in the application. Solution 1. Close the specific form in the Form Designer within IDE. 2. Navigate to //forms/tablet folder from Windows Explorer. 3. Open the form file (.kl file) in a text editor like Notepad, WordPad, and so on. 4. Search for and change its value from 0 to 100. 5. Save the .kl file and close it. 6. Refresh the tablet folder located under /forms in the IDE.

Emulators view is missing/empty after installing KonyOne Studio. Cause Some files might got corrupted or not installed properly while installing KonyOne Studio.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 9 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Solution To solve the above problem, reinstall KonyOne Studio. Kony Perspective is missing after upgrading few plugins using option available in Help Menu. I followed the below procedure: I installed 5.0.0GA using KonyOne Studio installer and later upgraded to 5.0.2GA manually (deleting old plugins and updating the latest in plugins folder). I have used the upgrade option available in the Help Menu to upgrade to 5.0.3GA plugins. I successfully upgraded without any errors but the Kony perspective is missing ( Emulator View, Application Views etc.). Cause Its a configuration issue when you have installed KonyOne Studio by manually copying the plugins to the dropins folder. Solution If you install KonyOne Studio manually copying the plugins to the dropins folder then make sure to delete all the plugins in the dropins folder before upgrading KonyOne Studio.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 10 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

3. Build Problems This section provides solutions to the problems that you may encounter while building application in KonyOne Studio. Build for BlackBerry platform failed with the following message: Ant build error=Unable to delete file C:\Program Files\Research In Motion\BlackBerry JDE 4.7.0\simulator\Test-bb-47.cod Ant build error=Unable to copy file E:\runtimeEclipseApplication\temp\Test\build\luaj2me\blackberry \dist\konyapi-bb-46-rel.cod to C:\Program Files\Research In Motion\BlackBerry JDE 4.7.0\simulator\Test-bb-47.cod java.io.FileNotFoundException Cause Emulators are installed in C:/Program Files folder and this folder has restricted access. Solution The following are the possible solutions: l

l

Install the emulators in another folder that does not have any access restrictions. Assign full permissions to the folder C:/Program Files.

Build for Android platform failed with the following message: Ant build error=Unable to copy file -debug.apk file or ANT_HOME not set Cause Multiple versions of Apache ANT exist in your local machine. Solution Delete all the versions of ANT that are not applicable.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 11 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

"Ant build error=Unable to delete directory" error occurs when a Clean and Build is performed. Cause Temporary files present in the location /temp/ are in use by external applications like Notepad, Command Prompt, Browser, and so on. Solution Close all the applications that are using the temporary files and rebuild the application. Build for Android fails with a "Debug Certificate Expired" message. Cause Problem with the debug.keystore file. Solution 1. Navigate to C:\Users\\.android folder on your machine. 2. Delete the debug.keystore file. 3. Perform a Clean and Build operation on the application for Android. 4. New debug.keystore file will be created automatically.

Build for Mobile Web fails with a "Unable to generate code for the categoryType 73" message. Cause Few forms in the application are marked as render Off for Mobile Web and render On for Mixed Mode. Solution 1. Mark render On for all the forms for Mobile Web. Or, mark render Off for all the forms for Mixed Mode. 2. Rebuild the application.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 12 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Android Build fails with a "Error. You are using an obsolete build.xml" message. Cause Minimum version of supported Android SDK and the compatible Kony plug-ins are not available. Solution Check and install the minimum version of required Android SDK and the latest Kony Android plug-ins. A message is displayed as "Target id is not valid. Use 'android.bat list targets' to get the target ids" in KonyOne Studio console after clicking Android Emulator. Cause Android SDK packages are not available. Solution Follow the below steps to solve the problem: 1. Run Android SDK Manager Setup.exe and click on Available Packages on the left side. 2. Check the Platforms you need. Select Google APIs along with Android API packages. 3. Click Install Selected. In KonyOne Studio, create the AVD ( TargetName - GoogleAPIs, API Level - above8) When building for Android platform a message is displayed as "\dist\test\build.xml:30: taskdef class com.android.ant.SetupTask cannot be found." Cause Android configurations are not set properly/not available. Solution Follow the below steps to solve the problem: l

Check Android SDK is installed properly.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 13 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

l

Please make sure you have Android_Home set in IDE. To set Android Home, from KonyOne Studio menu select Windows -> Preferences -> Kony Dev Studio -> Build ->(Browse and select Android SDK path).

l

Check anttasks.jar is present in \tools\lib folder.

l

Check if the environment variables are set properly for java, ant etc.

For example, JAVA_HOME = C:\Program Files\Java\jdk1.6.0_34 ANT_HOME = C:\apache-ant-1.8.4 PATH = C:\KonyOne\ImageMagick;C:\KonyOne\Ant\bin;C:\Program Files\Android\android-sdk\platform-tools\;C:\Program Files\Android\android-sdk\tools;C:\Program Files\Java\jdk1.6.0_34\bin A message is displayed as "Windows cannot find 'emulator.exe'. Make sure you typed the name correctly, and then try again." in KonyOne Studio console after clicking Android Emulator. Cause Android SDK packages are not available. Solution Follow the below steps to solve the problem: 1. Run Android SDK Manager Setup.exe and click on Available Packages on the left side. 2. Select Google APIs along with Android API packages. 3. Click Install Selected. In KonyOne Studio, create the AVD ( TargetName - GoogleAPIs, API Level - above8) A message is displayed as "Buildfile: C:\Documents does not exist!" in KonyOne Studio console after building for Android. Cause KonyOne Studio does not accept spaces in the workspace folder name.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 14 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Solution Always create the workspace which does not have spaces in it. For example, your workspace folder name should be "MySample" rather then "My Sample". A message is displayed as "adb.exe is not recognized as an internal or external command" in KonyOne Studio console after clicking Android Emulator. Cause Android_Home set in KonyOne Studio or adb.exe is not available in correct location. Solution To set Android Home, from KonyOne Studio menu select Windows -> Preferences -> Kony Dev Studio -> Build ->(Browse and select Android SDK path). Make sure adb.exe file is available in android-sdk\tools\ Unable to build application for windows 8 tablet. An error message is displayed in KonyOne Studio console. Cause Developer may not be an administrator or not having admin privileges on the system. Solution Developer should have admin privileges on the system or run the command prompt as administrator to execute the steps to build windows 8 tablet. Unable to build application for Android platform. An error message is displayed in KonyOne Studio console. I could trace the error in the console which reads as: [exec] [aapt] res\drawable\bestbuylogo.png:0: error: Resource entry bestbuylogo is already defined. [exec] [aapt] res\drawable\bestbuylogo.jpg:0: Originally defined here.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 15 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

Cause Android build fails if we have same file names with different extension in resources folder. In the above case we can see two images (bestbuylogo) as .png and .jpg. Solution Rename the files to have unique names.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 16 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

4. Kony Applications This section explains a few problems you may encounter with the applications built using KonyOne Studio. Each problem has a solution listed against it. Unable to scroll the data within a Segment beyond the application footer on Android Native Application. Cause Screenlevelwidget property of the Segment marked as false or other widgets on the form (Map, Browser) have the screenlevelwidget property marked as true. Solution The following are the possible solutions: l

l

If the screenlevelwidget property of Segment is not set to false, mark it as true. For more information about when to use the screenlevelwidget property, see Kony Widget User Guide or KonyOne Platform Application Design Guidelines document. Check if other widgets in the same form have this property set to true. If yes, set it as false for other widgets.

Note: This solution holds good for Segment, Browser, and Map widgets. If multiple widgets have this property set to true, the information in these widgets may not display with appropriate scrolling behavior.

No focus on menu and bookmark in map screen on Blackberry devices. l

l

The menu does not appear properly on the browser widget. The text disappears and the menu is not clickable. App menu gets hidden behind the map.

Cause Map and Browser widgets are native widgets and are drawn on a different layer than the other widgets. Solution A possible work around is to avoid the menu button to be shown on these screens. Instead, have the options included in the BlackBerry application menu (the native menu).

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 17 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

How can I preview the forms in the application without building the application at least once for Blackberry platform. For Blackberry platform, you cannot preview the application without build it for at least once. Blackberry uses a special preview application that is packaged along with KonyOne Blackberry plugin. This application is unpacked when you build the application for the first build.

Accessing KonyOne Server or URL over HTTPS using self-signed certificate fails with message "The certificate for this server is invalid. You might be connecting to a server that is pretending to be XXXXX which could put your confidential information at risk." Cause As your certificate is self-signed, iOS can't validate the certificate - there is no trusted authority in the system that has signed the certificate, so it has no basis for saying that it is valid. So if you ask it to validate the certificate (which is the default), it has to reject it. Solution Allow self-signed certificates from Kony Studio. To do so, 1. Right click the project and navigate to Properties > Native App > iPhone/iPad. 2. Under the Platform Settings pane, set Allow Self Signed Certificate to true. 3. After doing so, you will be able to sync your application. Note: We recommend that you turn off this setting when going to Production or App Store as this puts the application at risk.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 18 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

5. Symbolicating iPhone application crash reports Symbolicating iPhone application crash reports is a two step process. Firstly set the build values for an application and project before building on Xcode and secondly, follow the step-by-step process to exactly as mentioned below.

5.1 Settings to build the application on Xcode Ensure the following build settings are set to build an application in Release/Distribution configuration. 1. Set the values for an application during the build (For example, App1, App2, App3 etc.).

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 19 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

2. Set the values for a project during the build.

3. Once the application is build in "Build and Archive" mode, open Xcode Organizer and navigate to archived applications.

4. Identify the archived application that needs to be generated as an IPA file and reveal the build in finder.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 20 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

5. You will find three files (plist file, application package(.app) and a dSYM file). dSYM and the application package are used for symbolicating the crash reports.

6. Copy dSYM and the application package to a safe location in your system.

5.2 Symbolicating Crash Reports When ever a crash report is sent for the application IPA, open the crash report in a Mac machine. It shows the crash report and the stack trace with all the hexadecimal numbers. These hexadecimal codes are not much of use to analyze the specifics of the crash.

Note: If you are symbolicating an application that is build by others, then you also need IPA application and the dSYM files that are generated using the above procedure.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 21 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

1. To symbolicate the crash report file, copy the file in the same location where the dSYM and application package files are located. You can also use IPA file instead of application package.

2. Open Xcode Organizer and navigate to Debug Logs screen.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 22 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

3. Drag and Drop the crash report into the Crash Reports list widget of Debug Logs screen.

4. Xcode Organizer automatically Symbolicates the crash report and all the hexadecimal codes are changed to respective symbol names (Class names, function names etc.).

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 23 of 24

KonyOne Studio Troubleshooting Guide - Ver 5.0

5. Right-click on the Symbolicated list entry in Crash Reports list and reveal the log in finder.

6. You will find the newly generated Symbolicated file. Open the file in crash reporter (by double-clicking) to check and ensure that the symbolication is successful.

7. Share the file to Kony support team for further debugging/analysis.

Copyright © 2013 Kony, Inc. All Rights Reserved.

Page 24 of 24