{ "id": "170344", "key": "TIMOB-25523", "fields": { "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "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": null, "resolutiondate": null, "created": "2017-11-16T15:24:24.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [], "versions": [ { "id": "19904", "description": "", "name": "Hyperloop 3.0.0", "archived": false, "released": true, "releaseDate": "2017-12-07" } ], "issuelinks": [ { "id": "56149", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "167446", "key": "TIMOB-24657", "fields": { "summary": "Hyperloop: Android - Support to catch native exceptions", "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" } }, "priority": { "name": "Critical", "id": "1" }, "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "subtask": false } } } } ], "assignee": { "name": "jvennemann", "key": "jvennemann", "displayName": "Jan Vennemann", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2018-03-28T18:48:05.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" }, { "id": "13715", "name": "Hyperloop", "description": "Hyperloop project" } ], "description": "With TIMOB-24657 we allowed exceptions to bubble up to JS so they can be utilized in try-catch-blocks. All exception will be converted to strings though, so there cannot be done any type checking against the exception class, which is crucial in Java. The following approach solves this issue:\r\n\r\n* Throw a special {{HyperloopException}} from Java based on a catched {{InvocationTargetException}}.\r\n* Handle those exception in https://github.com/appcelerator/titanium_mobile/blob/master/android/runtime/v8/src/native/JSException.cpp#L37. Get the original exception via {{getCause()}} and construct a {{HyperloopNativeExceptionError}} in JS which allows the developer to access the underlying native Exception", "attachment": [], "flagged": false, "summary": "Hyperloop: Android - Add support to catch typed exceptions", "creator": { "name": "jvennemann", "key": "jvennemann", "displayName": "Jan Vennemann", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "jvennemann", "key": "jvennemann", "displayName": "Jan Vennemann", "active": true, "timeZone": "Europe/Berlin" }, "environment": null, "comment": { "comments": [], "maxResults": 0, "total": 0, "startAt": 0 } } }