{ "id": "92528", "key": "TIMOB-9361", "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": "13502", "description": "Sprint 2012-14 Core", "name": "Sprint 2012-14 Core", "archived": true, "released": true, "releaseDate": "2012-07-15" }, { "id": "13505", "description": "Release 3.0.0", "name": "Release 3.0.0", "archived": true, "released": true, "releaseDate": "2012-12-14" } ], "resolution": null, "resolutiondate": null, "created": "2012-05-30T04:39:42.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "core", "engSchedule", "module_webview", "qe-review", "qe-testadded" ], "versions": [ { "id": "13271", "description": "Release 2.1.0", "name": "Release 2.1.0", "archived": false, "released": true, "releaseDate": "2012-06-29" }, { "id": "20791", "name": "Release 8.0.2", "archived": false, "released": true, "releaseDate": "2019-06-18" }, { "id": "20412", "name": "Release 8.1.0", "archived": false, "released": true, "releaseDate": "2019-08-13" } ], "issuelinks": [], "assignee": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2019-10-29T15:38:28.000+0000", "status": { "description": "This issue was once resolved, but the resolution was deemed incorrect. From here issues are either marked assigned or resolved.", "name": "Reopened", "id": "4", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" } ], "description": "WRT Github pull request : https://github.com/appcelerator/titanium_mobile/pull/910\r\n\r\nWhen an Android webView attempts to load a non-existent url (for example), no error is fired (as documented!) \r\n\r\n{code:title=app.js|borderStyle=solid}\r\n// example: app.js\r\n\r\nvar win = Ti.UI.createWindow({\r\n\r\nbackgroundColor:'#fff'\r\n\r\n});\r\n\r\nvar web = Ti.UI.createWebView({\r\n\r\n// a clearly incorrect url\r\n\r\nurl:'http://google.cooom'\r\n\r\n});\r\n\r\nweb.addEventListener('error',function(e){\r\n\r\n\tTi.API.info('ERROR: '+JSON.stringify(e));\r\n\talert('ERROR: type:'+e.type+'\\nurl:'+e.url);\r\n\r\n});\r\n\r\nwin.add(web);\r\nwin.open();\r\n\r\n{code}", "attachment": [], "flagged": false, "summary": "Android: WebView has no error event", "creator": { "name": "kosso", "key": "kosso", "displayName": "kosso", "active": true, "timeZone": "Europe/London" }, "subtasks": [], "reporter": { "name": "kosso", "key": "kosso", "displayName": "kosso", "active": true, "timeZone": "Europe/London" }, "environment": "Android", "comment": { "comments": [ { "id": "201464", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "h3. Testing Notes\r\n\r\n* Run below app.js on *both iOS and Android*.\r\n\r\n{code:title=app.js}\r\nvar win = Ti.UI.createWindow({\r\n\tbackgroundColor:'#fff'\r\n});\r\n \r\nvar web = Ti.UI.createWebView({\r\n\turl:'http://google.cooom' // BAD URL\r\n});\r\n \r\nweb.addEventListener('error',function(e){\r\n\tvar message = e.message;\r\n\tvar code = e.errorCode;\r\n\tif (code == Ti.UI.URL_ERROR_HOST_LOOKUP) {\r\n\t\tmessage = \"Titanium.UI.URL_ERROR_HOST_LOOKUP - \" + message;\r\n\t}\r\n\tvar url = e.url;\r\n\talert(\"Error url: \" + url + \"; Error code: \" + code + \"; Error message: \" + message);\r\n \r\n});\r\n \r\nwin.add(web);\r\nwin.open();\r\n{code}\r\n\r\n* You should see an alert showing you an error code, the erroring url and the error message. The message and the numeric code value are platform specific, however the code should match the constant Titanium.UI.URL_ERROR_HOST_LOOKUP. If it does match that, the message will begin with a prepended \"Titanium.UI.URL_ERROR_HOST_LOOKUP\". <-- you should see that at the front of the message.\r\n\r\n* No sense testing in MobileWeb, that event never fires and anyway a code is not available there.\r\n\r\n* Run {{python validate.py -e -s simple -f Titanium/UI/WebView.yml}} and {{python docgen.py}} to make sure there are no errors *related to the WebView documentation*.", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2012-07-03T16:45:28.000+0000", "updated": "2012-07-05T12:03:17.000+0000" }, { "id": "201621", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "PR ready\r\n\r\nhttps://github.com/appcelerator/titanium_mobile/pull/2509", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2012-07-05T12:07:19.000+0000", "updated": "2012-07-05T12:07:19.000+0000" }, { "id": "214699", "author": { "name": "tsmolich", "key": "tsmolich", "displayName": "Tamila Smolich", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing as fixed.\r\nTested and verified on:\r\nTitanium Studio, build: 2.1.1.201208091713\r\nTitanium SDK, build: 2.2.0.v20120813184911\r\nDevices: Nexus 7 tab (4.1.1)\r\n\r\nThe expected alert is shown.", "updateAuthor": { "name": "tsmolich", "key": "tsmolich", "displayName": "Tamila Smolich", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-08-15T17:03:48.000+0000", "updated": "2012-08-15T17:03:48.000+0000" }, { "id": "217956", "author": { "name": "amittal", "key": "amittal", "displayName": "Anshu Mittal", "active": true, "timeZone": "America/Los_Angeles" }, "body": "reopening to update labels", "updateAuthor": { "name": "amittal", "key": "amittal", "displayName": "Anshu Mittal", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-09-07T04:35:39.000+0000", "updated": "2012-09-07T04:35:39.000+0000" }, { "id": "449903", "author": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Re-opening as on iOS the error code and error message show {{undefined}}. Or should I create a new ticket? [~vijaysingh]", "updateAuthor": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-07-18T13:33:15.000+0000", "updated": "2019-07-18T13:36:12.000+0000" }, { "id": "452319", "author": { "name": "ahutton", "key": "ahutton", "displayName": "Alan Hutton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Still showing as undefined. ", "updateAuthor": { "name": "ahutton", "key": "ahutton", "displayName": "Alan Hutton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-10-28T20:36:26.000+0000", "updated": "2019-10-28T20:36:26.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }