{ "id": "100173", "key": "TIMOB-10711", "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": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2017-07-26T23:45:36.000+0000", "created": "2012-08-30T05:00:05.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "api", "qe-ios082012" ], "versions": [ { "id": "13505", "description": "Release 3.0.0", "name": "Release 3.0.0", "archived": true, "released": true, "releaseDate": "2012-12-14" }, { "id": "14162", "description": "Release 3.1.0", "name": "Release 3.1.0", "archived": true, "released": true, "releaseDate": "2013-04-16" } ], "issuelinks": [], "assignee": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2017-07-26T23:45:36.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": "This is not a regression. It exists as far as 2.0.1.\r\nThis issue also occurs on android.\r\n\r\nSteps to reproduce:\r\n1) Use the code below and copy the attached text file in the resource directory.\r\n{code}\r\nvar win  = Ti.UI.createWindow({\r\n    backgroundColor: 'white'\r\n});\r\nwin.open();\r\n \r\nvar f = Titanium.Filesystem.getFile(Titanium.Filesystem.resourcesDirectory, 'text.txt');\r\n\t\r\n\tvar contents = f.read();\r\n\tTi.API.info(\"contents blob object = \"+ contents);\r\n\tTi.API.info('contents = ' + contents.text);\r\n{code}\r\n2. Notice the logs\r\n\r\nExpected result:\r\nLogs should display results like\r\n[INFO] contents blob object = [object TiBlob]\r\n[INFO] contents = Hello World. this is a filesystem read test.\r\n\r\nActual result:\r\nLogs display\r\n[INFO] contents blob object = Hello World. this is a filesystem read test.\r\n[INFO] contents = Hello World. this is a filesystem read test.\r\n\r\nExpected results are seen when image file is used instead of text file.", "attachment": [ { "id": "30890", "filename": "text.txt", "author": { "name": "sbhadauria", "key": "sbhadauria", "displayName": "Shyam Bhadauria", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-08-30T05:07:53.000+0000", "size": 44, "mimeType": "text/plain" } ], "flagged": false, "summary": "iOS: read() method of filesystem not returning blob type for text file", "creator": { "name": "sbhadauria", "key": "sbhadauria", "displayName": "Shyam Bhadauria", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "sbhadauria", "key": "sbhadauria", "displayName": "Shyam Bhadauria", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Tested with Titanium SDK: 2.2.0.v20120828153312\r\nTested with Titanium  Studio: 2.1.2.201208201549\r\nDevice - iOS 5.1 simulator,Android 2.2 emulator\r\nMachine OS - MAC 10.8", "comment": { "comments": [ { "id": "246615", "author": { "name": "shameerj", "key": "shameerj", "displayName": "Shameer Jan", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Issue reproduces \n\nTested with\n\nTitanium Studio, build: 3.0.1.201212181159\nTitanium SDK version: 3.1.0 \nTitanium SDK version: 3.0.2 \niOS iPhone Simulator: iOS SDK version: 6.0\n", "updateAuthor": { "name": "shameerj", "key": "shameerj", "displayName": "Shameer Jan", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-04-09T10:51:00.000+0000", "updated": "2013-04-09T10:51:00.000+0000" }, { "id": "424860", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Closing due to inactivity. If this issue still exists, please raise a new ticket.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-07-26T23:45:36.000+0000", "updated": "2017-07-26T23:45:36.000+0000" } ], "maxResults": 2, "total": 2, "startAt": 0 } } }