{"action":"created","issue":{"url":"https://api.github.com/repos/rom-rb/rom/issues/203","labels_url":"https://api.github.com/repos/rom-rb/rom/issues/203/labels{/name}","comments_url":"https://api.github.com/repos/rom-rb/rom/issues/203/comments","events_url":"https://api.github.com/repos/rom-rb/rom/issues/203/events","html_url":"https://github.com/rom-rb/rom/issues/203","id":67505472,"number":203,"title":"Allow Array defaults on Postgres array columns","user":{"login":"schwern","id":25888,"avatar_url":"https://avatars.githubusercontent.com/u/25888?v=3","gravatar_id":"","url":"https://api.github.com/users/schwern","html_url":"https://github.com/schwern","followers_url":"https://api.github.com/users/schwern/followers","following_url":"https://api.github.com/users/schwern/following{/other_user}","gists_url":"https://api.github.com/users/schwern/gists{/gist_id}","starred_url":"https://api.github.com/users/schwern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/schwern/subscriptions","organizations_url":"https://api.github.com/users/schwern/orgs","repos_url":"https://api.github.com/users/schwern/repos","events_url":"https://api.github.com/users/schwern/events{/privacy}","received_events_url":"https://api.github.com/users/schwern/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-04-10T04:16:51Z","updated_at":"2015-04-10T23:50:15Z","closed_at":"2015-04-10T23:50:15Z","body":"It would be nice if one could specify defaults on Postgres array columns as Ruby arrays.\r\n\r\n    column :titles, 'varchar[]', default: []\r\n\r\nThis solves two problems.  First, `default: []` is currently ignored with no warning.  The column will wind up with no default.\r\n\r\nSecond, if it has a not null constraint auto_validations will not see it has a default and do a presence validation.  auto_validations looks only for a ruby_default (possibly a bug).  This makes it difficult to use auto_validations with Postgres arrays.\r\n\r\n<bountysource-plugin>\r\n---\r\nWant to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/10831421-allow-array-defaults-on-postgres-array-columns?utm_campaign=plugin&utm_content=tracker%2F155789&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F155789&utm_medium=issues&utm_source=github).\r\n</bountysource-plugin>"},"comment":{"url":"https://api.github.com/repos/rom-rb/rom/issues/comments/91720632","html_url":"https://github.com/rom-rb/rom/issues/203#issuecomment-91720632","issue_url":"https://api.github.com/repos/rom-rb/rom/issues/203","id":91720632,"user":{"login":"schwern","id":25888,"avatar_url":"https://avatars.githubusercontent.com/u/25888?v=3","gravatar_id":"","url":"https://api.github.com/users/schwern","html_url":"https://github.com/schwern","followers_url":"https://api.github.com/users/schwern/followers","following_url":"https://api.github.com/users/schwern/following{/other_user}","gists_url":"https://api.github.com/users/schwern/gists{/gist_id}","starred_url":"https://api.github.com/users/schwern/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/schwern/subscriptions","organizations_url":"https://api.github.com/users/schwern/orgs","repos_url":"https://api.github.com/users/schwern/repos","events_url":"https://api.github.com/users/schwern/events{/privacy}","received_events_url":"https://api.github.com/users/schwern/received_events","type":"User","site_admin":false},"created_at":"2015-04-10T23:50:15Z","updated_at":"2015-04-10T23:50:15Z","body":"Exactly, I meant to report this to Sequel.  I'm not sure how I landed here."}}