{ "id": "173080", "key": "TIMOB-26876", "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": "20844", "name": "Hyperloop 4.0.3", "archived": false, "released": true, "releaseDate": "2019-06-25" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2019-06-25T20:46:00.000+0000", "created": "2019-03-04T18:15:25.000+0000", "epic": { "id": 173613, "key": "TISTUD-9169", "name": "Fix Debugging", "summary": "Fix miscellaneous debugger issues", "color": { "key": "color_1" }, "done": false }, "priority": { "name": "None", "id": "6" }, "labels": [], "versions": [], "issuelinks": [], "assignee": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "updated": "2019-06-25T20:46: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": "13715", "name": "Hyperloop", "description": "Hyperloop project" }, { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "Cannot debug a project that has hyperloop enabled. The issue is with debug on iOS only as the debug on same project works fine wth Android\r\n\r\nSteps to Reproduce:\r\n1. Create a default titanium project with services enabled\r\n2. Add a breakpoint in the js file\r\n3. Debug on iOS simulator or device\r\n\r\nActual Result:\r\nThe breakpoints are not hit during the debug. If we remove hyperloop from the project the same breakpoints are hit successfully.\r\n\r\nExpected Result:\r\nThe debug should work even for projects with hyperloop", "attachment": [], "flagged": false, "summary": "iOS: Cannot debug a project with hyperloop enabled", "creator": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Mac OS 10.14.3\r\nTi SDK: 8.0.0.v20190219113758, 7.5.0.GA\r\nAppc CLI: 7.0.10-master.17\r\nNode: 8.12.0\r\nJDK: 9.0.4\r\nStudio: 5.1.1.201809051655\r\nXCode: 10.1\r\nHyperloop: 3.1.4, 4.0.1", "closedSprints": [ { "id": 1129, "state": "closed", "name": "2019 Sprint 10", "startDate": "2019-04-28T22:06:00.000Z", "endDate": "2019-05-17T22:06:00.000Z", "completeDate": "2019-05-20T16:48:42.522Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "446771", "author": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I took a look at this today and with my testing I was able to use the debugger with Hyperloop enabled in the {{tiapp.xml}}. \r\n\r\n*Test Environment*\r\n{code:java}\r\niphone 6 (12.1 Sim)\r\nAppc Studio: {{5.1.2.201903111843}}\r\nSDK: {{8.0.0.v20190311082612}}\r\nAlloy and Titanium applications \r\n{code}\r\n", "updateAuthor": { "name": "smohammed", "key": "smohammed", "displayName": "Samir Mohammed", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-03-12T16:34:59.000+0000", "updated": "2019-03-12T16:34:59.000+0000" }, { "id": "448532", "author": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Still can see some issues with debug when hyperloop is enabled. There is a distinguished difference in debug behaviour when hyperloop is enabled for the project and when it's removed.\r\nFollow the steps below to notice the difference in debug behaviour:\r\n1. Create a new alloy project using the \"Default Alloy Project\" template and with services enabled.\r\n2. In index.js file, add a breakpoint at line 2 which is _alert($.label.text);_\r\n3. Now debug on iOS simulator\r\n4. Next from tiapp.xml, remove the hyperloop module for iOS.\r\n5. Again debug on iOS simulator\r\n\r\nActual Results:\r\nAfter Step 3: Notice the debug suspends during app launch and the breakpoint we added on line 2 is hit during app launch itself. It was supposed to be hit when we click on the label not on app launch. Click on resume. When app launches click on the \"Hello, World\" label. No breakpoint is hit.\r\nAfter Step 5: No breakpoint is hit during app launch. The app launches. Click on \"Hello, World\" label and the breakpoint on line 2 is hit.\r\n\r\nNote: On Android we see the same behaviour on step 3 and step 5 which is same as what we see on step 5 when debug on iOS.\r\n\r\nVerified using Studio: 5.2.0.201905172239 and Ti SDK: 8.1.0.v20190520081553", "updateAuthor": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-05-20T18:22:17.000+0000", "updated": "2019-05-20T18:22:17.000+0000" }, { "id": "449230", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "Note that [~eharris] and [~shaig] also ran into an issue here. It appears that adding hyperloop to the project will result in it injecting additional newlines into the generated code - leading to the breakpoint lines not matching up.\r\n\r\nThe most likely culprit here is hyperloop transforming the code via babel in some way that does not retain the same line numbers. Hopefully the fix is as simple as passing an option to tell babel to retain lines. The more complicated options is to try and merge source maps again like we do in node-titanium-sdk's jsanalyze method.", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2019-06-20T13:40:30.000+0000", "updated": "2019-06-20T13:40:30.000+0000" }, { "id": "449233", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "Hyperloop is unnecessarily modifying JS files on iOS when nothing should be changing.\r\n\r\nOn Android, it doesn't seem to cause a bug, but it is still doing unnecessary work (re-generating source from the AST) if we don't change the AST (find usage of a hyperloop require/import).", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2019-06-20T15:06:57.000+0000", "updated": "2019-06-20T15:06:57.000+0000" }, { "id": "449234", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "https://github.com/appcelerator/hyperloop.next/pull/321", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2019-06-20T15:24:41.000+0000", "updated": "2019-06-20T15:24:41.000+0000" }, { "id": "449342", "author": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "body": "FR Passed. Debug of project with Hyperloop works fine on iOS and android. ", "updateAuthor": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-06-25T20:35:57.000+0000", "updated": "2019-06-25T20:35:57.000+0000" }, { "id": "449343", "author": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified on:\r\nMac OS 10.14.3\r\nTi SDK: 8.1.0.v20190619134801\r\nAppc CLI: 7.1.0-master.22\r\nNode: 10.13.0\r\nAlloy: 1.14.0-1\r\nHyperloop: 4.0.3\r\nJDK: 1.8.0_144\r\nXcode: 10.2.1", "updateAuthor": { "name": "ssekhri", "key": "ssekhri", "displayName": "Satyam Sekhri", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2019-06-25T20:46:00.000+0000", "updated": "2019-06-25T20:46:00.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }