{"action":"created","comment":{"url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/comments/105859258","pull_request_review_id":26756444,"id":105859258,"diff_hunk":"@@ -0,0 +1,21 @@\n+CREATE OR REPLACE FUNCTION unfix_color(color INTEGER) RETURNS INTEGER AS $$\n+\n+DECLARE\n+    least_3_bytes CONSTANT INTEGER := (1 << 24) - 1;\n+    least_1_byte CONSTANT INTEGER := (1 << 8) - 1;\n+    rgb INTEGER;\n+    alpha INTEGER;\n+\n+BEGIN\n+    rgb := color >> 8 & least_3_bytes;\n+    alpha := color & least_1_byte;\n+    RETURN alpha << 24 | rgb;\n+\n+END;$$ LANGUAGE plpgsql;\n+\n+UPDATE shape\n+  SET strokecolor = CASE WHEN strokecolor IS NOT NULL THEN unfix_color(strokecolor) END,\n+      fillcolor   = CASE WHEN fillcolor   IS NOT NULL THEN unfix_color(fillcolor)   END\n+  WHERE (strokecolor IS NOT NULL OR\n+         fillcolor   IS NOT NULL) AND\n+        TRUE;","path":"sql/psql/OMERO5.3__0/reverse_shape_color_argb_to_rgba.sql","position":21,"original_position":21,"commit_id":"37935f54f4419535d6876bc3b59ff88ca46090cd","original_commit_id":"37935f54f4419535d6876bc3b59ff88ca46090cd","user":{"login":"mtbc","id":2630707,"avatar_url":"https://avatars1.githubusercontent.com/u/2630707?v=3","gravatar_id":"","url":"https://api.github.com/users/mtbc","html_url":"https://github.com/mtbc","followers_url":"https://api.github.com/users/mtbc/followers","following_url":"https://api.github.com/users/mtbc/following{/other_user}","gists_url":"https://api.github.com/users/mtbc/gists{/gist_id}","starred_url":"https://api.github.com/users/mtbc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mtbc/subscriptions","organizations_url":"https://api.github.com/users/mtbc/orgs","repos_url":"https://api.github.com/users/mtbc/repos","events_url":"https://api.github.com/users/mtbc/events{/privacy}","received_events_url":"https://api.github.com/users/mtbc/received_events","type":"User","site_admin":false},"body":"could add a comment here saying to adjust as required","created_at":"2017-03-14T09:27:19Z","updated_at":"2017-03-14T09:27:19Z","html_url":"https://github.com/openmicroscopy/openmicroscopy/pull/5182#discussion_r105859258","pull_request_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182","_links":{"self":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/comments/105859258"},"html":{"href":"https://github.com/openmicroscopy/openmicroscopy/pull/5182#discussion_r105859258"},"pull_request":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182"}}},"pull_request":{"url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182","id":110577999,"html_url":"https://github.com/openmicroscopy/openmicroscopy/pull/5182","diff_url":"https://github.com/openmicroscopy/openmicroscopy/pull/5182.diff","patch_url":"https://github.com/openmicroscopy/openmicroscopy/pull/5182.patch","issue_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues/5182","number":5182,"state":"open","locked":false,"title":"color scripts","user":{"login":"jburel","id":1022396,"avatar_url":"https://avatars2.githubusercontent.com/u/1022396?v=3","gravatar_id":"","url":"https://api.github.com/users/jburel","html_url":"https://github.com/jburel","followers_url":"https://api.github.com/users/jburel/followers","following_url":"https://api.github.com/users/jburel/following{/other_user}","gists_url":"https://api.github.com/users/jburel/gists{/gist_id}","starred_url":"https://api.github.com/users/jburel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jburel/subscriptions","organizations_url":"https://api.github.com/users/jburel/orgs","repos_url":"https://api.github.com/users/jburel/repos","events_url":"https://api.github.com/users/jburel/events{/privacy}","received_events_url":"https://api.github.com/users/jburel/received_events","type":"User","site_admin":false},"body":"# What this PR does\r\n\r\nAdd scripts used to reset the color of shape to match data model\r\n\r\n# Testing this PR\r\n\r\nScripts have already been tested but a final check will be good\r\n\r\nTo test:\r\n * Using 5.2 server, create shape and set fill color and stroke color\r\n * Upgrade to 5.3. Check the color, they should not match the ones previously set\r\n * Run shape_color script to reset the color. They should now match the color created in 5.2\r\n\r\n# Related reading\r\n\r\nhttps://trello.com/c/sGlYbbvB/213-color-in-shape-settings\r\n\r\ncc @bramalingam @mtbc ","created_at":"2017-03-14T09:26:16Z","updated_at":"2017-03-14T09:27:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f58006aedc6bef71440c487bbd919504f112618b","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182/commits","review_comments_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182/comments","review_comment_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/comments{/number}","comments_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues/5182/comments","statuses_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/statuses/37935f54f4419535d6876bc3b59ff88ca46090cd","head":{"label":"jburel:sql-script","ref":"sql-script","sha":"37935f54f4419535d6876bc3b59ff88ca46090cd","user":{"login":"jburel","id":1022396,"avatar_url":"https://avatars2.githubusercontent.com/u/1022396?v=3","gravatar_id":"","url":"https://api.github.com/users/jburel","html_url":"https://github.com/jburel","followers_url":"https://api.github.com/users/jburel/followers","following_url":"https://api.github.com/users/jburel/following{/other_user}","gists_url":"https://api.github.com/users/jburel/gists{/gist_id}","starred_url":"https://api.github.com/users/jburel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jburel/subscriptions","organizations_url":"https://api.github.com/users/jburel/orgs","repos_url":"https://api.github.com/users/jburel/repos","events_url":"https://api.github.com/users/jburel/events{/privacy}","received_events_url":"https://api.github.com/users/jburel/received_events","type":"User","site_admin":false},"repo":{"id":2315069,"name":"openmicroscopy","full_name":"jburel/openmicroscopy","owner":{"login":"jburel","id":1022396,"avatar_url":"https://avatars2.githubusercontent.com/u/1022396?v=3","gravatar_id":"","url":"https://api.github.com/users/jburel","html_url":"https://github.com/jburel","followers_url":"https://api.github.com/users/jburel/followers","following_url":"https://api.github.com/users/jburel/following{/other_user}","gists_url":"https://api.github.com/users/jburel/gists{/gist_id}","starred_url":"https://api.github.com/users/jburel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jburel/subscriptions","organizations_url":"https://api.github.com/users/jburel/orgs","repos_url":"https://api.github.com/users/jburel/repos","events_url":"https://api.github.com/users/jburel/events{/privacy}","received_events_url":"https://api.github.com/users/jburel/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jburel/openmicroscopy","description":"OME (Open Microscopy Environment) develops open-source software and data format standards for the storage and manipulation of biological light microscopy data. A joint project between universities, research establishments and industry in Europe and the USA, OME has over 20 active researchers with strong links to the microscopy community. Funded by private and public research grants, OME has been a major force on the international microscopy stage since 2000.","fork":true,"url":"https://api.github.com/repos/jburel/openmicroscopy","forks_url":"https://api.github.com/repos/jburel/openmicroscopy/forks","keys_url":"https://api.github.com/repos/jburel/openmicroscopy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jburel/openmicroscopy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jburel/openmicroscopy/teams","hooks_url":"https://api.github.com/repos/jburel/openmicroscopy/hooks","issue_events_url":"https://api.github.com/repos/jburel/openmicroscopy/issues/events{/number}","events_url":"https://api.github.com/repos/jburel/openmicroscopy/events","assignees_url":"https://api.github.com/repos/jburel/openmicroscopy/assignees{/user}","branches_url":"https://api.github.com/repos/jburel/openmicroscopy/branches{/branch}","tags_url":"https://api.github.com/repos/jburel/openmicroscopy/tags","blobs_url":"https://api.github.com/repos/jburel/openmicroscopy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jburel/openmicroscopy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jburel/openmicroscopy/git/refs{/sha}","trees_url":"https://api.github.com/repos/jburel/openmicroscopy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jburel/openmicroscopy/statuses/{sha}","languages_url":"https://api.github.com/repos/jburel/openmicroscopy/languages","stargazers_url":"https://api.github.com/repos/jburel/openmicroscopy/stargazers","contributors_url":"https://api.github.com/repos/jburel/openmicroscopy/contributors","subscribers_url":"https://api.github.com/repos/jburel/openmicroscopy/subscribers","subscription_url":"https://api.github.com/repos/jburel/openmicroscopy/subscription","commits_url":"https://api.github.com/repos/jburel/openmicroscopy/commits{/sha}","git_commits_url":"https://api.github.com/repos/jburel/openmicroscopy/git/commits{/sha}","comments_url":"https://api.github.com/repos/jburel/openmicroscopy/comments{/number}","issue_comment_url":"https://api.github.com/repos/jburel/openmicroscopy/issues/comments{/number}","contents_url":"https://api.github.com/repos/jburel/openmicroscopy/contents/{+path}","compare_url":"https://api.github.com/repos/jburel/openmicroscopy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jburel/openmicroscopy/merges","archive_url":"https://api.github.com/repos/jburel/openmicroscopy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jburel/openmicroscopy/downloads","issues_url":"https://api.github.com/repos/jburel/openmicroscopy/issues{/number}","pulls_url":"https://api.github.com/repos/jburel/openmicroscopy/pulls{/number}","milestones_url":"https://api.github.com/repos/jburel/openmicroscopy/milestones{/number}","notifications_url":"https://api.github.com/repos/jburel/openmicroscopy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jburel/openmicroscopy/labels{/name}","releases_url":"https://api.github.com/repos/jburel/openmicroscopy/releases{/id}","deployments_url":"https://api.github.com/repos/jburel/openmicroscopy/deployments","created_at":"2011-09-02T16:40:24Z","updated_at":"2017-01-20T21:01:48Z","pushed_at":"2017-03-14T09:21:24Z","git_url":"git://github.com/jburel/openmicroscopy.git","ssh_url":"git@github.com:jburel/openmicroscopy.git","clone_url":"https://github.com/jburel/openmicroscopy.git","svn_url":"https://github.com/jburel/openmicroscopy","homepage":"http://www.openmicroscopy.org","size":2084572,"stargazers_count":5,"watchers_count":5,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":5,"default_branch":"java9"}},"base":{"label":"openmicroscopy:develop","ref":"develop","sha":"226e79f69367f0ecc88da18b70dc3dc954ffe8af","user":{"login":"openmicroscopy","id":975861,"avatar_url":"https://avatars1.githubusercontent.com/u/975861?v=3","gravatar_id":"","url":"https://api.github.com/users/openmicroscopy","html_url":"https://github.com/openmicroscopy","followers_url":"https://api.github.com/users/openmicroscopy/followers","following_url":"https://api.github.com/users/openmicroscopy/following{/other_user}","gists_url":"https://api.github.com/users/openmicroscopy/gists{/gist_id}","starred_url":"https://api.github.com/users/openmicroscopy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openmicroscopy/subscriptions","organizations_url":"https://api.github.com/users/openmicroscopy/orgs","repos_url":"https://api.github.com/users/openmicroscopy/repos","events_url":"https://api.github.com/users/openmicroscopy/events{/privacy}","received_events_url":"https://api.github.com/users/openmicroscopy/received_events","type":"Organization","site_admin":false},"repo":{"id":2228226,"name":"openmicroscopy","full_name":"openmicroscopy/openmicroscopy","owner":{"login":"openmicroscopy","id":975861,"avatar_url":"https://avatars1.githubusercontent.com/u/975861?v=3","gravatar_id":"","url":"https://api.github.com/users/openmicroscopy","html_url":"https://github.com/openmicroscopy","followers_url":"https://api.github.com/users/openmicroscopy/followers","following_url":"https://api.github.com/users/openmicroscopy/following{/other_user}","gists_url":"https://api.github.com/users/openmicroscopy/gists{/gist_id}","starred_url":"https://api.github.com/users/openmicroscopy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/openmicroscopy/subscriptions","organizations_url":"https://api.github.com/users/openmicroscopy/orgs","repos_url":"https://api.github.com/users/openmicroscopy/repos","events_url":"https://api.github.com/users/openmicroscopy/events{/privacy}","received_events_url":"https://api.github.com/users/openmicroscopy/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/openmicroscopy/openmicroscopy","description":"OME (Open Microscopy Environment) develops open-source software and data format standards for the storage and manipulation of biological light microscopy data. A joint project between universities, research establishments and industry in Europe and the USA, OME has over 20 active researchers with strong links to the microscopy community. Funded by private and public research grants, OME has been a major force on the international microscopy stage since 2000.","fork":false,"url":"https://api.github.com/repos/openmicroscopy/openmicroscopy","forks_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/forks","keys_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/keys{/key_id}","collaborators_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/teams","hooks_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/hooks","issue_events_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues/events{/number}","events_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/events","assignees_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/assignees{/user}","branches_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/branches{/branch}","tags_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/tags","blobs_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/git/refs{/sha}","trees_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/git/trees{/sha}","statuses_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/statuses/{sha}","languages_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/languages","stargazers_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/stargazers","contributors_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/contributors","subscribers_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/subscribers","subscription_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/subscription","commits_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/commits{/sha}","git_commits_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/git/commits{/sha}","comments_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/comments{/number}","issue_comment_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues/comments{/number}","contents_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/contents/{+path}","compare_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/compare/{base}...{head}","merges_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/merges","archive_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/downloads","issues_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues{/number}","pulls_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls{/number}","milestones_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/milestones{/number}","notifications_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/labels{/name}","releases_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/releases{/id}","deployments_url":"https://api.github.com/repos/openmicroscopy/openmicroscopy/deployments","created_at":"2011-08-18T14:26:02Z","updated_at":"2017-03-08T18:13:29Z","pushed_at":"2017-03-14T09:26:17Z","git_url":"git://github.com/openmicroscopy/openmicroscopy.git","ssh_url":"git@github.com:openmicroscopy/openmicroscopy.git","clone_url":"https://github.com/openmicroscopy/openmicroscopy.git","svn_url":"https://github.com/openmicroscopy/openmicroscopy","homepage":"http://www.openmicroscopy.org","size":1971200,"stargazers_count":94,"watchers_count":94,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":77,"mirror_url":null,"open_issues_count":23,"forks":77,"open_issues":23,"watchers":94,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182"},"html":{"href":"https://github.com/openmicroscopy/openmicroscopy/pull/5182"},"issue":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues/5182"},"comments":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/issues/5182/comments"},"review_comments":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182/comments"},"review_comment":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/pulls/5182/commits"},"statuses":{"href":"https://api.github.com/repos/openmicroscopy/openmicroscopy/statuses/37935f54f4419535d6876bc3b59ff88ca46090cd"}}}}
{"actor":{"display_login":"mtbc"}}