{"action":"created","comment":{"url":"https://api.github.com/repos/CartoDB/cartodb/pulls/comments/167175810","pull_request_review_id":95357004,"id":167175810,"diff_hunk":"@@ -9,10 +9,10 @@\n \n   def response_grants_should_include_request_permissions(reponse_grants, table_permissions)\n     table_permissions.each do |stp|\n-      response_tables = reponse_grants.find { |grant| grant['type'] == 'database'}['tables']\n+      response_tables = reponse_grants.find { |grant| grant[:type] == 'database'}[:tables]","path":"spec/requests/carto/api/api_keys_controller_spec.rb","position":5,"original_position":5,"commit_id":"82f3aaa0548bfb60902a532189500f54ce3e235f","original_commit_id":"82f3aaa0548bfb60902a532189500f54ce3e235f","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Space missing inside }.","created_at":"2018-02-09T09:22:56Z","updated_at":"2018-02-09T09:22:56Z","html_url":"https://github.com/CartoDB/cartodb/pull/11735#discussion_r167175810","pull_request_url":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/CartoDB/cartodb/pulls/comments/167175810"},"html":{"href":"https://github.com/CartoDB/cartodb/pull/11735#discussion_r167175810"},"pull_request":{"href":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735"}}},"pull_request":{"url":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735","id":109955491,"html_url":"https://github.com/CartoDB/cartodb/pull/11735","diff_url":"https://github.com/CartoDB/cartodb/pull/11735.diff","patch_url":"https://github.com/CartoDB/cartodb/pull/11735.patch","issue_url":"https://api.github.com/repos/CartoDB/cartodb/issues/11735","number":11735,"state":"open","locked":false,"title":"Rails 4 support","user":{"login":"javitonino","id":7569673,"avatar_url":"https://avatars3.githubusercontent.com/u/7569673?v=4","gravatar_id":"","url":"https://api.github.com/users/javitonino","html_url":"https://github.com/javitonino","followers_url":"https://api.github.com/users/javitonino/followers","following_url":"https://api.github.com/users/javitonino/following{/other_user}","gists_url":"https://api.github.com/users/javitonino/gists{/gist_id}","starred_url":"https://api.github.com/users/javitonino/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javitonino/subscriptions","organizations_url":"https://api.github.com/users/javitonino/orgs","repos_url":"https://api.github.com/users/javitonino/repos","events_url":"https://api.github.com/users/javitonino/events{/privacy}","received_events_url":"https://api.github.com/users/javitonino/received_events","type":"User","site_admin":false},"body":"WIP\r\n\r\n[R3C] = I think it should be compatible with Rails 3, can be applied without updating Rails.\r\n\r\n- ~~Updated Sequel-Rails. Added a monkey patch because we were using a Vizzuality fork with an extra function. Now it's running on rubygems version. It implied a massive search/replace among many files (including DB migrations) [R3C]~~\r\n- Added `protected_attributes` gem, as support is dropped in Rails 3. This also forbids us to goind straight to Rails 5. We need to migrate to strong parameters first.\r\n  - Add strong parameters to controllers when needed to keep working. **TODO**: Actually use them properly.\r\n- The syntax for AR scopes changes a bit in Rails 4. Now, passing a block is mandatory. ~~[R3C]~~\r\n- Deprecated activerecord-postgresql-array. Support is now built-in.\r\n  - **TODO**: This should let us remove the visualization tags hack\r\n- Postgresql JSON fields are now automatically serialized/deserialized. Updated the serializer to support this case.\r\n- Rails 4 deprecates `config.threadsafe!` Removed it.\r\n  - **TODO:** Check if the multithreaded mode still works. (auto-reloading does).\r\n- ~~Fix routes file incompatibilities.~~\r\n  - ~~Main one was using `match` without specifying verbs. [R3C]~~\r\n  - ~~`format: :json` is now written as `defaults: { format: :json }` [R3C]~~\r\n- Fix an issue with the legends validator [R3C]\r\n- ~~Updated oauth gem [R3C]~~\r\n- Updated state_machine gem ~~[R3C]~~\r\n- Updated to Rails 4.2 (initially tried to 4.1, but there is a serious bug where `dependent: :destroy` doesn't work with FKs)\r\n  - There is another FK bug in Rails 4 with bi-directional `dependent: :destroy`. I added a (hacky)  \r\nworkaround.\r\n  - Had to remove `ssl_required`, using Rails functionality in its place.\r\n  - We should consider if we can enable SSL globally (there are some tickets about this, only thing we may want to keep HTTP are old embeds)\r\n- ~~Modified `verb_json` test helpers to pass HTTP Header `Accept: application/json`. Before, this was being done with `format: json`, which is not supposed to work (but it did because Rails 3 merged `params` and `headers`) [R3C]~~\r\n- ~~Session objects are slightly different in Rails 4. Added `to_hash` to make compatible [R3C]~~\r\n- Differences in AR timezone handling. In Rails 3, all dates are returned in UTC. In Rails 4 they use the proper timezone. I cheated a bit in a couple of tests to get this passing.\r\n- Changed API keys internal format, accept `null` meaning `[]`. Careful with this. Rationale in the commit https://github.com/CartoDB/cartodb/pull/11735/commits/2f9ed0b2d2ce999108464320b8d4c44cdd2a3a95","created_at":"2017-03-09T16:43:24Z","updated_at":"2018-02-09T09:22:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6c44a4bcd7871565fbb0b5574cbd455cd1e4e33a","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"milestone":null,"commits_url":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735/commits","review_comments_url":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735/comments","review_comment_url":"https://api.github.com/repos/CartoDB/cartodb/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CartoDB/cartodb/issues/11735/comments","statuses_url":"https://api.github.com/repos/CartoDB/cartodb/statuses/82f3aaa0548bfb60902a532189500f54ce3e235f","head":{"label":"CartoDB:rails4","ref":"rails4","sha":"82f3aaa0548bfb60902a532189500f54ce3e235f","user":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars0.githubusercontent.com/u/1799254?v=4","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"repo":{"id":4909355,"name":"cartodb","full_name":"CartoDB/cartodb","owner":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars0.githubusercontent.com/u/1799254?v=4","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CartoDB/cartodb","description":"Location Intelligence & Data Visualization tool","fork":false,"url":"https://api.github.com/repos/CartoDB/cartodb","forks_url":"https://api.github.com/repos/CartoDB/cartodb/forks","keys_url":"https://api.github.com/repos/CartoDB/cartodb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CartoDB/cartodb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CartoDB/cartodb/teams","hooks_url":"https://api.github.com/repos/CartoDB/cartodb/hooks","issue_events_url":"https://api.github.com/repos/CartoDB/cartodb/issues/events{/number}","events_url":"https://api.github.com/repos/CartoDB/cartodb/events","assignees_url":"https://api.github.com/repos/CartoDB/cartodb/assignees{/user}","branches_url":"https://api.github.com/repos/CartoDB/cartodb/branches{/branch}","tags_url":"https://api.github.com/repos/CartoDB/cartodb/tags","blobs_url":"https://api.github.com/repos/CartoDB/cartodb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CartoDB/cartodb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CartoDB/cartodb/git/refs{/sha}","trees_url":"https://api.github.com/repos/CartoDB/cartodb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CartoDB/cartodb/statuses/{sha}","languages_url":"https://api.github.com/repos/CartoDB/cartodb/languages","stargazers_url":"https://api.github.com/repos/CartoDB/cartodb/stargazers","contributors_url":"https://api.github.com/repos/CartoDB/cartodb/contributors","subscribers_url":"https://api.github.com/repos/CartoDB/cartodb/subscribers","subscription_url":"https://api.github.com/repos/CartoDB/cartodb/subscription","commits_url":"https://api.github.com/repos/CartoDB/cartodb/commits{/sha}","git_commits_url":"https://api.github.com/repos/CartoDB/cartodb/git/commits{/sha}","comments_url":"https://api.github.com/repos/CartoDB/cartodb/comments{/number}","issue_comment_url":"https://api.github.com/repos/CartoDB/cartodb/issues/comments{/number}","contents_url":"https://api.github.com/repos/CartoDB/cartodb/contents/{+path}","compare_url":"https://api.github.com/repos/CartoDB/cartodb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CartoDB/cartodb/merges","archive_url":"https://api.github.com/repos/CartoDB/cartodb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CartoDB/cartodb/downloads","issues_url":"https://api.github.com/repos/CartoDB/cartodb/issues{/number}","pulls_url":"https://api.github.com/repos/CartoDB/cartodb/pulls{/number}","milestones_url":"https://api.github.com/repos/CartoDB/cartodb/milestones{/number}","notifications_url":"https://api.github.com/repos/CartoDB/cartodb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CartoDB/cartodb/labels{/name}","releases_url":"https://api.github.com/repos/CartoDB/cartodb/releases{/id}","deployments_url":"https://api.github.com/repos/CartoDB/cartodb/deployments","created_at":"2012-07-05T15:23:45Z","updated_at":"2018-02-09T06:56:48Z","pushed_at":"2018-02-09T09:22:20Z","git_url":"git://github.com/CartoDB/cartodb.git","ssh_url":"git@github.com:CartoDB/cartodb.git","clone_url":"https://github.com/CartoDB/cartodb.git","svn_url":"https://github.com/CartoDB/cartodb","homepage":"http://carto.com","size":373595,"stargazers_count":1734,"watchers_count":1734,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":483,"mirror_url":null,"archived":false,"open_issues_count":764,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":483,"open_issues":764,"watchers":1734,"default_branch":"master"}},"base":{"label":"CartoDB:master","ref":"master","sha":"7a8a0c24c15be3aeb59e167ec4ad4f420b8e4a40","user":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars0.githubusercontent.com/u/1799254?v=4","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"repo":{"id":4909355,"name":"cartodb","full_name":"CartoDB/cartodb","owner":{"login":"CartoDB","id":1799254,"avatar_url":"https://avatars0.githubusercontent.com/u/1799254?v=4","gravatar_id":"","url":"https://api.github.com/users/CartoDB","html_url":"https://github.com/CartoDB","followers_url":"https://api.github.com/users/CartoDB/followers","following_url":"https://api.github.com/users/CartoDB/following{/other_user}","gists_url":"https://api.github.com/users/CartoDB/gists{/gist_id}","starred_url":"https://api.github.com/users/CartoDB/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CartoDB/subscriptions","organizations_url":"https://api.github.com/users/CartoDB/orgs","repos_url":"https://api.github.com/users/CartoDB/repos","events_url":"https://api.github.com/users/CartoDB/events{/privacy}","received_events_url":"https://api.github.com/users/CartoDB/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CartoDB/cartodb","description":"Location Intelligence & Data Visualization tool","fork":false,"url":"https://api.github.com/repos/CartoDB/cartodb","forks_url":"https://api.github.com/repos/CartoDB/cartodb/forks","keys_url":"https://api.github.com/repos/CartoDB/cartodb/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CartoDB/cartodb/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CartoDB/cartodb/teams","hooks_url":"https://api.github.com/repos/CartoDB/cartodb/hooks","issue_events_url":"https://api.github.com/repos/CartoDB/cartodb/issues/events{/number}","events_url":"https://api.github.com/repos/CartoDB/cartodb/events","assignees_url":"https://api.github.com/repos/CartoDB/cartodb/assignees{/user}","branches_url":"https://api.github.com/repos/CartoDB/cartodb/branches{/branch}","tags_url":"https://api.github.com/repos/CartoDB/cartodb/tags","blobs_url":"https://api.github.com/repos/CartoDB/cartodb/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CartoDB/cartodb/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CartoDB/cartodb/git/refs{/sha}","trees_url":"https://api.github.com/repos/CartoDB/cartodb/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CartoDB/cartodb/statuses/{sha}","languages_url":"https://api.github.com/repos/CartoDB/cartodb/languages","stargazers_url":"https://api.github.com/repos/CartoDB/cartodb/stargazers","contributors_url":"https://api.github.com/repos/CartoDB/cartodb/contributors","subscribers_url":"https://api.github.com/repos/CartoDB/cartodb/subscribers","subscription_url":"https://api.github.com/repos/CartoDB/cartodb/subscription","commits_url":"https://api.github.com/repos/CartoDB/cartodb/commits{/sha}","git_commits_url":"https://api.github.com/repos/CartoDB/cartodb/git/commits{/sha}","comments_url":"https://api.github.com/repos/CartoDB/cartodb/comments{/number}","issue_comment_url":"https://api.github.com/repos/CartoDB/cartodb/issues/comments{/number}","contents_url":"https://api.github.com/repos/CartoDB/cartodb/contents/{+path}","compare_url":"https://api.github.com/repos/CartoDB/cartodb/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CartoDB/cartodb/merges","archive_url":"https://api.github.com/repos/CartoDB/cartodb/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CartoDB/cartodb/downloads","issues_url":"https://api.github.com/repos/CartoDB/cartodb/issues{/number}","pulls_url":"https://api.github.com/repos/CartoDB/cartodb/pulls{/number}","milestones_url":"https://api.github.com/repos/CartoDB/cartodb/milestones{/number}","notifications_url":"https://api.github.com/repos/CartoDB/cartodb/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CartoDB/cartodb/labels{/name}","releases_url":"https://api.github.com/repos/CartoDB/cartodb/releases{/id}","deployments_url":"https://api.github.com/repos/CartoDB/cartodb/deployments","created_at":"2012-07-05T15:23:45Z","updated_at":"2018-02-09T06:56:48Z","pushed_at":"2018-02-09T09:22:20Z","git_url":"git://github.com/CartoDB/cartodb.git","ssh_url":"git@github.com:CartoDB/cartodb.git","clone_url":"https://github.com/CartoDB/cartodb.git","svn_url":"https://github.com/CartoDB/cartodb","homepage":"http://carto.com","size":373595,"stargazers_count":1734,"watchers_count":1734,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":483,"mirror_url":null,"archived":false,"open_issues_count":764,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause"},"forks":483,"open_issues":764,"watchers":1734,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735"},"html":{"href":"https://github.com/CartoDB/cartodb/pull/11735"},"issue":{"href":"https://api.github.com/repos/CartoDB/cartodb/issues/11735"},"comments":{"href":"https://api.github.com/repos/CartoDB/cartodb/issues/11735/comments"},"review_comments":{"href":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735/comments"},"review_comment":{"href":"https://api.github.com/repos/CartoDB/cartodb/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CartoDB/cartodb/pulls/11735/commits"},"statuses":{"href":"https://api.github.com/repos/CartoDB/cartodb/statuses/82f3aaa0548bfb60902a532189500f54ce3e235f"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"houndci-bot"}}