{ "id": "110681", "key": "TIMOB-12969", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "15274", "description": "2013 Sprint 06 API", "name": "2013 Sprint 06 API", "archived": true, "released": true, "releaseDate": "2013-03-25" }, { "id": "14816", "description": "2013 Sprint 06", "name": "2013 Sprint 06", "archived": true, "released": true, "releaseDate": "2013-03-25" } ], "resolution": { "id": "5", "description": "All attempts at reproducing this issue failed, or not enough information was available to reproduce the issue. Reading the code produces no clues as to why this behavior would occur. If more information appears later, please reopen the issue.", "name": "Cannot Reproduce" }, "resolutiondate": "2013-03-20T23:44:40.000+0000", "created": "2013-03-06T09:37:23.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "mobilesdk", "module", "titanium" ], "versions": [ { "id": "14161", "description": "Release 3.0.1", "name": "Release 3.0.1", "archived": true, "released": true, "releaseDate": "2013-02-19" }, { "id": "14164", "description": "Release 3.0.2", "name": "Release 3.0.2", "archived": true, "released": true, "releaseDate": "2013-02-19" } ], "issuelinks": [ { "id": "26881", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "111435", "key": "TIMOB-13124", "fields": { "summary": "Expose a hard crash in the crash_test_dummy module", "status": { "description": "This issue is being actively worked on at the moment by the assignee.", "name": "In Progress", "id": "3", "statusCategory": { "id": 4, "key": "indeterminate", "colorName": "yellow", "name": "In Progress" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "7", "description": "gh.issue.story.desc", "name": "Story", "subtask": false } } } } ], "assignee": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-03-21T21:36:56.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "I Tested the sample code provided with Crittercism module and found that live stats are not working for Crash and Handled Exception with Android 2.2 and above.\r\nAlso i get app load only for 1st time app launch with Titanium SDK version change. like when i change TiSDK from 3.0.0 to 3.0.2 or vice versa.\r\n\r\n{code}\r\nTi.API.info(\"Ti App: importing Crittercism...\");\r\nvar crittercism = require('com.crittercism.ti.android');\r\nTi.API.info(\"module is => \" + crittercism + \"\\n\");\r\n\r\nTi.API.info(\"Ti App: initializing Crittercism...\");\r\n\r\ncrittercism.init(\"5004e9d1be790e78f2000006\");\r\n\r\nTi.API.info(\"Ti App: Crittercism initialized\\n\");\r\n\r\nvar win = Titanium.UI.createWindow({\r\n\ttitle : 'Crittercism Test',\r\n\tbackgroundColor : '#fff'\r\n});\r\ncrittercism.leaveBreadcrumb(\"Creating window\");\r\n\r\nvar topLabel = Titanium.UI.createLabel({\r\n\ttop:10,\r\n\tcolor : '#999',\r\n\ttext : 'Crittercism Test App!',\r\n\tfont : {\r\n\t\tfontSize : 16,\r\n\t\tfontFamily : 'Helvetica Neue'\r\n\t},\r\n\twidth : 'auto'\r\n});\r\n\r\nwin.add(topLabel);\r\n\r\nvar setMetaData = Titanium.UI.createButton({\r\n\ttop:35,\r\n\twidth:301,\r\n\theight:30,\r\n\ttitle:'Set Metadata'\r\n});\r\n\r\nsetMetaData.addEventListener('click', function()\r\n{\r\n\tcrittercism.leaveBreadcrumb(\"setMetaData // Setting Username\");\r\n\tcrittercism.setUsername(\"TomCritter\");\r\n\ttry {\r\n\t\tcrittercism.leaveBreadcrumb(\"Attempting to add Metadata\");\r\n\t\tcrittercism.setMetadata({\r\n\t\t\t\"gameLevel\": 5,\r\n\t\t\t\"email\": \"support@crittercism.com\",\r\n\t\t\t\"playerID\": 9491824\r\n\t\t\t});\r\n\t} catch (e) {\r\n\t\tTi.API.error(\"set Metadata: JSON failed\");\r\n\t}\r\n\t\r\n});\r\n\r\nwin.add(setMetaData);\r\n\r\nvar crashButton = Titanium.UI.createButton({\r\n\ttop:70,\r\n\twidth:301,\r\n\theight:30,\r\n\ttitle:'Crash'\r\n});\r\n\r\ncrashButton.addEventListener('click', function()\r\n{\r\n\tcrittercism.leaveBreadcrumb(\"Clicking the crash button\");\r\n\t// create an array with an invalid size\r\n\tvar a = new Array(0x100000000);\r\n\t\r\n\tvar array = new Array();\r\n\t// access an index out of bounds\r\n\tarray[-4]; // this doesn't get caught\r\n\t\r\n\twin.add(array[-4]); // this gets caught\r\n\t\r\n\t// throw an exceptions\r\n\tvar er = new Error(\"My Not as Awesome Uncaught Error!\");\r\n\tthrow er\r\n});\r\n\r\nwin.add(crashButton);\r\n\r\nvar handledButton = Titanium.UI.createButton({\r\n\ttop:105,\r\n\twidth:301,\r\n\theight:30,\r\n\ttitle:'Send Handled Exception'\r\n});\r\n\r\nhandledButton.addEventListener('click', function()\r\n{\t\r\n\ttry {\r\n\t\tcrittercism.leaveBreadcrumb(\"Attempting some awesome task...\");\r\n\t\tvar err = new Error(\"My Awesome Caught Error!\");\r\n\t\tthrow err\r\n\t} catch (err){\r\n\t\tcrittercism.leaveBreadcrumb(\"Oh no, it failed! Log it...\");\r\n\t\tcrittercism.logHandledException({\r\n\t\t\tname: err.name,\r\n\t\t\tmessage: err.message,\r\n\t\t\tline:err.lineNumber\r\n\t\t});\r\n\t}\r\n});\r\n\r\nwin.add(handledButton);\r\n\r\nvar status = false;\r\n\r\nvar optOutToggle = Titanium.UI.createButton({\r\n\ttop:140,\r\n\twidth:301,\r\n\theight:30,\r\n\ttitle:'Toggle OptOut Status: No'\r\n});\r\n\r\noptOutToggle.addEventListener('click', function()\r\n{\r\n\t// Set the status\r\n\tcrittercism.setOptOutStatus(status = !status);\r\n\t\r\n\t// change the status in the button title for visibility\r\n\tvar stringStatus = crittercism.getOptOutStatus() ? \"Yes\" : \"No\";\r\n\toptOutToggle.title = 'Toggle OptOut Status: ' + stringStatus;\r\n});\r\n\r\nwin.add(optOutToggle);\r\n\r\nwin.open();\r\n\r\n\r\n{code}", "attachment": [], "flagged": false, "summary": "Crittercism module does not show any crash or handled exception in live stat section", "creator": { "name": "anigam", "key": "anigam", "displayName": "Ashish Nigam", "active": true, "timeZone": "Asia/Kolkata" }, "subtasks": [], "reporter": { "name": "anigam", "key": "anigam", "displayName": "Ashish Nigam", "active": true, "timeZone": "Asia/Kolkata" }, "environment": "Titanium Mobile, Android Module, Android.", "comment": { "comments": [ { "id": "243103", "author": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Max,\n\nWe tested the issue in house. Exceptions are getting populated into the dashboard properly. However, the crash reports not being recorded or get populated into the dashboard.\n\nShak", "updateAuthor": { "name": "shossain", "key": "shossain", "displayName": "Shak Hossain", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2013-03-20T02:08:06.000+0000", "updated": "2013-03-20T02:08:06.000+0000" }, { "id": "243275", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "When starting up, we see in logcat:\n{code}\nI/ActivityManager( 238): Start proc com.appcelerator.crittercismTest1 for activity com.appcelerator.crittercismTest1/.Crittercismtest1Activity: pid=16427 uid=10061 gids={1015, 1007, 3003}\nI/dalvikvm(16427): Turning on JNI app bug workarounds for target SDK version 8...\n...\nI/TiAPI (16427): Ti App: importing Crittercism...\nI/TiAPI (16427): module is => [object Object]\nI/TiAPI (16427): Ti App: initializing Crittercism...\nI/APACHE HTTP (thCr=24364) - NafHttpAuthStrategyDefault(16427): (thUse=24364) NafHttpAuthStrategyDefault()\nI/APACHE HTTP (thCr=24364) - KeeperManager(16427): (thUse=24364) INITIALIZATION of shared resources\nI/APACHE HTTP (thCr=24364) - AndroidContextProviderImpl(16427): (thUse=24364) currentActivityThread=null\nI/APACHE HTTP (thCr=24364) - GbaSupportIndicatorRequestUpdaterDefault(16427): (thUse=24364) GbaSupportIndicatorRequestUpdaterAbstract() userHeaderPredefined=null\nI/Crittercism(16427): Crittercism Initialized.\nI/Crittercism(16427): sendAppLoadData() will only send data to Crittercism if \"delaySendingAppLoad\" is set to true in the configuration settings you include in the init call.\nI/TiAPI (16427): Ti App: Crittercism initialized\nI/APACHE HTTP (thCr=24364) - NafHttpAuthStrategyDefault(16427): (thUse=24370) cached value : gbaSupportIsPossible=null\nI/APACHE HTTP (thCr=24364) - NafHttpAuthStrategyDefault(16427): (thUse=24370) The current context is NOT a context of GBA service.\nI/APACHE HTTP (thCr=24364) - GbaSupportPermissionRequestCheckerImpl(16427): (thUse=24370) isCurrentProcessRequestedGba()#finished result=false\nI/APACHE HTTP (thCr=24364) - GbaSupportPermissionRequestCheckerImpl(16427): (thUse=24370) isCurrentProcessAllowedToUseGba()#started result=false\nI/APACHE HTTP (thCr=24364) - NafHttpAuthStrategyDefault(16427): (thUse=24370) The GBA permission wasn't requested for this process.\nI/APACHE HTTP (thCr=24364) - NafHttpAuthStrategyDefault(16427): (thUse=24370) It is impossible to support GBA now (many possible reasons: no Android Context, current client is GBA service, etc.), then it will be just usual HTTP.\nI/APACHE HTTP (thCr=24370) - NafRequestExecutorWrapperRedirectionHandler(16427): (thUse=24370) It isn't GBA flow, redirection responses are not handled.\n{code}\nStack Overflow says [this might be okay](http://stackoverflow.com/questions/11840937/apache-http-client-nafhttpauthstrategydefault).\n\nOdder and odder. In clicking the 'send handled exception', I see in the logcat:\n{code}\nI/System (16427): Failed to destroy process 16558\nI/System (16427): libcore.io.ErrnoException: kill failed: ESRCH (No such process)\nI/System (16427): \tat libcore.io.Posix.kill(Native Method)\nI/System (16427): \tat libcore.io.ForwardingOs.kill(ForwardingOs.java:77)\nI/System (16427): \tat java.lang.ProcessManager$ProcessImpl.destroy(ProcessManager.java:257)\nI/System (16427): \tat crittercism.android.b$a.d(Unknown Source)\nI/System (16427): \tat crittercism.android.b$a.call(Unknown Source)\nI/System (16427): \tat java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:305)\nI/System (16427): \tat java.util.concurrent.FutureTask.run(FutureTask.java:137)\nI/System (16427): \tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076)\nI/System (16427): \tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569)\nI/System (16427): \tat java.lang.Thread.run(Thread.java:864)\n{code}\n\nWithout much investigation into the code, this looks internal to Crittercism, given the class name does not have ti in the path.\n\nAs far as I can tell, Crittercism may have a service set up (the one we're trying to kill) and some logic is causing an exception to stop us from logging.\n\nQuestion is: Where do we go from here?\n\nAre we actually seeing any of this showing up on the crittercism site?", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-20T22:17:04.000+0000", "updated": "2013-03-20T22:17:04.000+0000" }, { "id": "243300", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Okay, an update:\n\nIn generating a new application code ( 514a43cf5f721646f000000a ) for the app, I could see the handled exceptions show up fine.\n\nDespite the button label, the crash is actually an exception, even if one presses Kill. Crash Test Dummy would be needed to test an actual crash.\n\nI'm not sure what the actual issue is. Moving to cannot reproduce until more detail is given.", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-20T23:43:35.000+0000", "updated": "2013-03-20T23:43:35.000+0000" }, { "id": "243301", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Please provide more information, and reopen then.", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-20T23:44:40.000+0000", "updated": "2013-03-20T23:44:40.000+0000" }, { "id": "414476", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing ticket as the issue cannot be reproduced and due to the above comments.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-03-21T21:36:56.000+0000", "updated": "2017-03-21T21:36:56.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }