{ "id": "99551", "key": "TIMOB-10530", "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": [], "resolution": { "id": "7", "description": "", "name": "Invalid" }, "resolutiondate": "2012-08-21T15:06:50.000+0000", "created": "2012-08-21T14:40:20.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "core" ], "versions": [ { "id": "13505", "description": "Release 3.0.0", "name": "Release 3.0.0", "archived": true, "released": true, "releaseDate": "2012-12-14" } ], "issuelinks": [], "assignee": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2014-06-19T12:44:39.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": "When making a JS call that binds to a Java method and an exception is thrown\r\nwe should catch it in Kroll and convert it into a JS exception.\r\n\r\nThis can allow developers to handle them more gracefully and also\r\npinpoints where in the JS code the crash originated. Having both a JS and Java\r\ntrace would be valuable in debugging platform bugs reported by our developers.\r\n\r\nThis also allows us to throw exception due to invalid calls.\r\nFor example if the developer calls View.add() passing a non-view we\r\ncan throw an exception. This provides a trace to the point of the error\r\nso the developer does not need to hunt for the bad JS call site.\r\n", "attachment": [], "flagged": false, "summary": "Android: Java exceptions should be converted and thrown as JS exceptions.", "creator": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "215438", "author": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Parity should also be considered on how we handle invalid method calls due to developer errors.\r\nAny intentional exceptions thrown should be consistent across all platforms.\r\nException specific to Android internals (ex: null pointer) can be an exception.", "updateAuthor": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-08-21T14:42:02.000+0000", "updated": "2012-08-21T14:42:02.000+0000" }, { "id": "215445", "author": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "body": "My bad this actually working fine for sync based calls. The case I was seeing was due to the exception getting thrown async on the UI thread. :\\", "updateAuthor": { "name": "joshroesslein", "key": "joshroesslein", "displayName": "Josh Roesslein", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-08-21T15:06:35.000+0000", "updated": "2012-08-21T15:06:35.000+0000" } ], "maxResults": 2, "total": 2, "startAt": 0 } } }