{ "id": "61865", "key": "TIMOB-1233", "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": "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": "2012-07-25T12:17:54.000+0000", "created": "2011-04-15T02:47:17.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [], "versions": [ { "id": "11225", "name": "Release 1.5.0", "archived": true, "released": true, "releaseDate": "2010-12-14" } ], "issuelinks": [ { "id": "19398", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "94532", "key": "TIMOB-9901", "fields": { "summary": "TiAPI: Review and clean up platform bugs and reduce bug count by 20%.", "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": "High", "id": "2" }, "issuetype": { "id": "7", "description": "gh.issue.story.desc", "name": "Story", "subtask": false } } } } ], "assignee": { "name": "ngupta", "key": "ngupta", "displayName": "Neeraj Gupta", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2012-07-26T22:26:00.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": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "{html}

First lets get some technical details out of the way:

\r\n\r\n

I discovered this bug trying to get oAuth working for Twitter.\r\nThe bug occurs when the Allow / Deny page is submitted. You will\r\nbriefly see the next page, with the authenication pin number, then\r\nthe app will crash with the following error:

\r\n
\r\n2010-07-06 10:23:56.850 iPadTest[7991:1803] *** -[DOMHTMLElement setHref:]: unrecognized selector sent to instance 0x6507cc0\r\n[ERROR] The application has crashed with an unhandled exception. Stack trace:\r\n0 CoreFoundation 0x0398d850 __exceptionPreprocess + 96\r\n1 libobjc.A.dylib 0x03aa832c objc_exception_throw + 44\r\n2 CoreFoundation 0x0398fa5b -[NSObject doesNotRecognizeSelector:] + 187\r\n3 CoreFoundation 0x0390c676 ___forwarding___ + 918\r\n4 CoreFoundation 0x0390b9f2 _CF_forwarding_prep_0 + 50\r\n5 DataDetectorsUI 0x0c58c3d8 -[DOMDocument(DDExtension) dd_urlifyResults:operation:] + 3255\r\n6 DataDetectorsUI 0x0c586cb8 -[DDDetectionController doURLificationOnWebThreadAndRelease:] + 543\r\n7 CoreFoundation 0x0390ba5d __invoking___ + 29\r\n8 CoreFoundation 0x0390b93a -[NSInvocation invoke] + 154\r\n9 WebCore 0x040bf723 _ZL15HandleAPISourcePv + 147\r\n10 CoreFoundation 0x038dce5a CFRunLoopRunSpecific + 1450\r\n11 CoreFoundation 0x038dc8a8 CFRunLoopRunInMode + 88\r\n12 WebCore 0x0404a633 _ZL12RunWebThreadPv + 467\r\n13 libSystem.B.dylib 0x91fdb81d _pthread_start + 345\r\n14 libSystem.B.dylib 0x91fdb6a2 thread_start + 34\r\n2010-07-06 10:23:56.853 iPadTest[7991:1803] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[DOMHTMLElement setHref:]: unrecognized selector sent to instance 0x6507cc0'\r\n2010-07-06 10:23:56.854 iPadTest[7991:1803] Stack: (\r\n60348496,\r\n61506348,\r\n60357211,\r\n59819638,\r\n59816434,\r\n207143896,\r\n207121592,\r\n59816541,\r\n59816250,\r\n67893027,\r\n59625050,\r\n59623592,\r\n67413555,\r\n2449324061,\r\n2449323682\r\n)\r\nterminate called after throwing an instance of 'NSException'\r\n[INFO] Application has exited from Simulator\r\n
\r\n

I have included the resources folder of an app that can\r\nreplicate this problem.

\r\n

Jim

{html}", "attachment": [ { "id": "17956", "filename": "resources.zip", "author": { "name": "jamespearson", "key": "jamespearson", "displayName": "James Pearson", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:47:17.000+0000", "size": 39237, "mimeType": "application/zip" } ], "flagged": false, "summary": "iOS: Webview crashes on Twitter oAuth pin page (1.3.2)", "creator": { "name": "jamespearson", "key": "jamespearson", "displayName": "James Pearson", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "jamespearson", "key": "jamespearson", "displayName": "James Pearson", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "125135", "author": { "name": "jamespearson", "key": "jamespearson", "displayName": "James Pearson", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

This also crashes in a build of 1.3.3, but the problem isn't\n(really) with Titanium, it is a bug in iOS4.

\n

The problem is with the WebView trying to recognise phone\nnumbers, while we can'r fix this problem in iOS, we can work around\nit by adding an option to ignore phone numbers in a webview...\nunfortunately that is beyond me on Objective-C, but here is where I\nfound the problem discussed:

\n

\nhttp://code.google.com/p/oauthconsumer-iphone/issues/detail?id=1&am...

\n

And here is their implementation of a fix:

\n

\nhttp://code.google.com/p/oauthconsumer-iphone/source/diff?spec=svn1...

\n

Jim

{html}", "updateAuthor": { "name": "jamespearson", "key": "jamespearson", "displayName": "James Pearson", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:47:17.000+0000", "updated": "2011-04-15T02:47:17.000+0000" }, { "id": "125136", "author": { "name": "davidr.", "key": "davidr.", "displayName": "David R.", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Hi Jeff,

\n

As a workaround in Titanium 1.3.x, it is possible to set the\nwebview autoDetect to AUTODETECT_NONE:

\n
\n         webView = Ti.UI.createWebView({\n            url: pUrl,\n            autoDetect:[Ti.UI.AUTODETECT_NONE]\n        });\n
{html}", "updateAuthor": { "name": "davidr.", "key": "davidr.", "displayName": "David R.", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:47:18.000+0000", "updated": "2011-04-15T02:47:18.000+0000" }, { "id": "125137", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

We should revisit this, maybe fixed, but headache.

{html}", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:47:19.000+0000", "updated": "2011-04-15T02:47:19.000+0000" }, { "id": "125138", "author": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Yes! Let's revisit this!

{html}", "updateAuthor": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:47:19.000+0000", "updated": "2011-04-15T02:47:19.000+0000" }, { "id": "209361", "author": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Unable to reproduce in SDK 2.2.0.f9e938d, iPhone Sim 5.1.", "updateAuthor": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-07-25T12:17:54.000+0000", "updated": "2012-07-25T12:17:54.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }