{ "id": "63482", "key": "TIMOB-2850", "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": "11239", "name": "Release 1.6.0 M06", "archived": true, "released": true, "releaseDate": "2011-01-24" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T02:00:15.000+0000", "created": "2011-04-15T03:31:08.000+0000", "priority": { "name": "Trivial", "id": "5" }, "labels": [ "android", "defect", "release-1.6.0", "reported-1.5.1", "yahoo" ], "versions": [], "issuelinks": [], "assignee": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2011-04-17T02:00:15.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": "{html}

Failcase app.js:

\n
\nTitanium.UI.setBackgroundColor('#000');\nTi.Yahoo.yql('select * from flickr.photos.search where text=\"Cat\" limit 10', function(e) { });\n
\n

Run that and it results in \"Cannot call method\n'createHTTPClient' of undefined\" error.

\n

If you modify it to look like this...

\n
\nTitanium.UI.setBackgroundColor('#000');\nTi.Network.creatHTTPClient(); // DUMMY\nTi.Yahoo.yql('select * from flickr.photos.search where text=\"Cat\" limit 10', function(e) { });\n
\n

... it will work without error. I presume this is because our\nmodule detection code will see that\nTi.Network.createHTTPClient and then include the\ntitanium-network module in the APK. It's required for our yahoo\nmodule because the yql stuff works by loading and eval'ing a\nspecial Javascript file, yahoo.js.

{html}", "attachment": [], "flagged": false, "summary": "Android: Yahoo module yql() calls fail if Ti.Network not used anywhere else in app", "creator": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "environment": null, "comment": { "comments": [ { "id": "129552", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

(from [8f40abf91e7ed13e99076a322dc82b3c6686b0d5])\n[#2850 state:fixed-in-qa] declare that yahoo\nmodule is dependent on network module. \nhttps://github.com/appcelerator/titanium_mobile/commit/8f40abf91e7e...

{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:31:09.000+0000", "updated": "2011-04-15T03:31:09.000+0000" }, { "id": "129553", "author": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "body": "{html}

(from [50e4fd31fa594381cad72b1b0e53790e0c39b9dd])\n[#2850 state:fixed-in-qa] declare that yahoo\nmodule is dependent on network module. \nhttps://github.com/appcelerator/titanium_mobile/commit/50e4fd31fa59...

{html}", "updateAuthor": { "name": "billdawson", "key": "billdawson", "displayName": "Bill Dawson", "active": true, "timeZone": "Europe/Berlin" }, "created": "2011-04-15T03:31:09.000+0000", "updated": "2011-04-15T03:31:09.000+0000" }, { "id": "129554", "author": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Verified on G1/1.6 and Nexus One/2.2.1 using build #e1cb22a

{html}", "updateAuthor": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:31:09.000+0000", "updated": "2011-04-15T03:31:09.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }