{ "id": "152142", "key": "AC-472", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2015-10-29T08:59:37.000+0000", "created": "2015-10-18T07:18:58.000+0000", "labels": [], "versions": [ { "id": "17033", "name": "Appcelerator Studio 4.3.1", "archived": false, "released": false } ], "issuelinks": [], "assignee": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "updated": "2015-10-29T09:00:03.000+0000", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "14548", "name": "Titanium SDK & CLI", "description": "Please enter tickets related to the MobileSDK here." } ], "description": "I send HTTP multipart request with te following code:\r\n\r\nthefile=Titanium.Filesystem.getFile(this.filepath_to_upload);\r\n \r\n postdata={\r\n name: this.guid,\r\n createDT:this.createDT+\"\",\r\n session_length:this.session_length+\"\",\r\n device_model:Titanium.Platform.getModel(),\r\n device_manufacturer:Titanium.Platform.getManufacturer(),\r\n device_osname:Titanium.Platform.getOsname(),\r\n device_version:Titanium.Platform.getVersion(),\r\n device_locale:Titanium.Platform.getLocale(),\r\n result_type:2, //for fitness=0, for science=1, for fitness+science =2\r\n debug:false, \r\n file: thefile\r\n };\r\n\r\nclient.open(\"POST\", url);\r\nclient.setRequestHeader(\r\n\t\t\t 'Authorization', \r\n\t\t\t 'Basic ' + Ti.Utils.base64encode(auth.username+':'+auth.password)\r\n\t\t );\r\nclient.setRequestHeader(\"enctype\", \"multipart/form-data\");\r\nclient.send(postdata);\r\n\r\nAnd the app composes inclosed name tags in the request, for example:\r\n\r\n---0Yp7DHdqG1dPhejcf_POatQ2DMYKnOxDBeC\r\nContent-Disposition: form-data; name=\"name\r\nContent-Type: ; charset=UTF-8\r\nContent-Transfer-Encoding: 8bit\r\n\r\n52959e65-8c74-c8c0-be18-90f047f5e9b6\r\n---0Yp7DHdqG1dPhejcf_POatQ2DMYKnOxDBeC\r\nContent-Disposition: form-data; name=\"device_locale\r\nContent-Type: ; charset=UTF-8\r\nContent-Transfer-Encoding: 8bit\r\n\r\nen-US\r\n---0Yp7DHdqG1dPhejcf_POatQ2DMYKnOxDBeC\r\nContent-Disposition: form-data; name=\"debug\r\nContent-Type: ; charset=UTF-8\r\nContent-Transfer-Encoding: 8bit\r\n\r\nOnly file field are formed correctly.\r\n\r\nThis appear in all versions of Titanium SDK 5, but if fall back to version 4 or 3 - all works perfectly.", "attachment": [ { "id": "57049", "filename": "devcenetr-tcpdump.txt", "author": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "created": "2015-10-18T07:18:18.000+0000", "size": 5442, "mimeType": "text/plain" } ], "flagged": false, "summary": "Multipart HTTP request composed with errors", "creator": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "subtasks": [], "reporter": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "environment": "Mac OS, Android and suppose iOS will face this too, but have not tested", "comment": { "comments": [ { "id": "367264", "author": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "body": "The error does not appear under iOS.", "updateAuthor": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "created": "2015-10-20T06:31:12.000+0000", "updated": "2015-10-20T06:31:12.000+0000" }, { "id": "368230", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "[~xvk@mail.ru] You can run `appc ti sdk install -d -b 5_0_X` on terminal to get an updated SDK. This should be fixed with that version of SDK. Let me know if it's working for you.", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-10-29T02:52:36.000+0000", "updated": "2015-10-29T02:52:36.000+0000" }, { "id": "368268", "author": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "body": "Yes, it is fine with this version. Thank you.", "updateAuthor": { "name": "xvk@mail.ru", "key": "xvk@mail.ru", "displayName": "Artem Akulshin", "active": true, "timeZone": "Europe/Moscow" }, "created": "2015-10-29T08:52:24.000+0000", "updated": "2015-10-29T08:52:24.000+0000" }, { "id": "368269", "author": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "body": "Thanks [~xvk@mail.ru] for the reply. Resolving issue! :)", "updateAuthor": { "name": "msamah", "key": "msamah", "displayName": "Ashraf Abu", "active": false, "timeZone": "Asia/Singapore" }, "created": "2015-10-29T08:59:51.000+0000", "updated": "2015-10-29T08:59:51.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }