{ "id": "149321", "key": "ALOY-1287", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "11113", "key": "ALOY", "name": "Alloy", "projectCategory": { "id": "10400", "description": "Tools for developing applications", "name": "Tooling" } }, "fixVersions": [ { "id": "16692", "name": "Alloy 1.7.0", "archived": false, "released": true, "releaseDate": "2015-07-22" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2015-07-29T00:06:48.000+0000", "created": "2015-07-01T08:29:12.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "defect" ], "versions": [], "issuelinks": [], "assignee": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2015-07-29T00:06:48.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": "13603", "name": "Styling", "description": "TSS, dynamic styling, styling API" } ], "description": "In some cases, when the developer overloads in a stylesheets some styles defined in the {{app.tss}} files, the alloy compilation won't produce the same resulting javascript accross successive compilations.\r\n\r\nAlloy's styler orders style rules to define their priority, but there's a bug with the {{app.tss}} global styles being cached and therefore not correctly being counted by the styler during a compilation phase when {{app.tss}} didn't change.\r\n\r\nSteps to reproduce:\r\n\r\n * create a new alloy app, replace its {{app}} folder with the one contained in the attached app.zip file\r\n * compile once: {{alloy compile --config platform=ios}}. Check in {{Resources/iphone/alloy/controllers/sum.js}} that the style rules defined in {{app/styles/sum.tss}} are applied correctly\r\n * compile again, the generated javascript in the {{Resources}} directory differ. In particular, the {{Resources/iphone/alloy/controllers/sum.js}} does only contain rules from the {{app.tss}} file.\r\n\r\nA PR is being proposed to fix this problem.", "attachment": [ { "id": "56028", "filename": "app.zip", "author": { "name": "xavier", "key": "xavier", "displayName": "Xavier Lacot", "active": true, "timeZone": "Europe/Paris" }, "created": "2015-07-01T08:28:07.000+0000", "size": 7603, "mimeType": "application/zip" } ], "flagged": false, "summary": "Alloy styles compilation does not produce the same results accross successive compilations", "creator": { "name": "xavier", "key": "xavier", "displayName": "Xavier Lacot", "active": true, "timeZone": "Europe/Paris" }, "subtasks": [], "reporter": { "name": "xavier", "key": "xavier", "displayName": "Xavier Lacot", "active": true, "timeZone": "Europe/Paris" }, "environment": "Latest version of alloy, from repository's master branch", "closedSprints": [ { "id": 455, "state": "closed", "name": "2015 Sprint 15 Tooling", "startDate": "2015-07-20T16:26:19.926Z", "endDate": "2015-08-08T01:26:00.000Z", "completeDate": "2015-08-03T20:10:37.386Z", "originBoardId": 121 } ], "comment": { "comments": [ { "id": "356526", "author": { "name": "xavier", "key": "xavier", "displayName": "Xavier Lacot", "active": true, "timeZone": "Europe/Paris" }, "body": "A Pull Request is available here: https://github.com/appcelerator/alloy/pull/704", "updateAuthor": { "name": "xavier", "key": "xavier", "displayName": "Xavier Lacot", "active": true, "timeZone": "Europe/Paris" }, "created": "2015-07-01T09:00:33.000+0000", "updated": "2015-07-01T09:00:33.000+0000" }, { "id": "357139", "author": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "body": "I just ran into this bug while creating https://github.com/appcelerator-developer-relations/appc-sample-ti410, thanks [~xavier]", "updateAuthor": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "created": "2015-07-07T12:08:40.000+0000", "updated": "2015-07-07T12:09:35.000+0000" }, { "id": "357140", "author": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "body": "Verified the bug using the attached sample app:\r\n\r\nFirst run, correctly mixing style from {{app.tss}} and {{sum.tss}}\r\n\r\n{code:javascript}\r\n $.__views.__alloyId0 = Ti.UI.createView({\r\n layout: \"vertical\",\r\n height: Ti.UI.SIZE,\r\n top: 10,\r\n right: 10,\r\n bottom: 5,\r\n left: 10,\r\n backgroundColor: \"red\",\r\n id: \"__alloyId0\"\r\n });\r\n{code}\r\n\r\nSecond run, missing the styles from {{sum.tss}}:\r\n\r\n{code:javascript}\r\n $.__views.__alloyId0 = Ti.UI.createView({\r\n top: 14,\r\n bottom: 15,\r\n backgroundColor: \"red\",\r\n layout: \"vertical\",\r\n height: Ti.UI.SIZE,\r\n right: 10,\r\n left: 10,\r\n id: \"__alloyId0\"\r\n });\r\n{code}\r\n\r\nAlso verified the PR, where both the first and second run correctly mix the style from {{app.tss}} and {{sum.tss}}.", "updateAuthor": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "created": "2015-07-07T12:17:09.000+0000", "updated": "2015-07-07T12:17:09.000+0000" }, { "id": "358466", "author": { "name": "fmiao", "key": "fmiao", "displayName": "Feon Sua Xin Miao", "active": true, "timeZone": "America/Vancouver" }, "body": "PR merged.", "updateAuthor": { "name": "fmiao", "key": "fmiao", "displayName": "Feon Sua Xin Miao", "active": true, "timeZone": "America/Vancouver" }, "created": "2015-07-29T00:06:48.000+0000", "updated": "2015-07-29T00:06:48.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }