{"action":"created","issue":{"url":"https://api.github.com/repos/masteringmodernpayments/book/issues/16","labels_url":"https://api.github.com/repos/masteringmodernpayments/book/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/masteringmodernpayments/book/issues/16/comments","events_url":"https://api.github.com/repos/masteringmodernpayments/book/issues/16/events","html_url":"https://github.com/masteringmodernpayments/book/issues/16","id":88850049,"number":16,"title":"Just started the basic integration","user":{"login":"farhansyed9","id":9581815,"avatar_url":"https://avatars.githubusercontent.com/u/9581815?v=3","gravatar_id":"","url":"https://api.github.com/users/farhansyed9","html_url":"https://github.com/farhansyed9","followers_url":"https://api.github.com/users/farhansyed9/followers","following_url":"https://api.github.com/users/farhansyed9/following{/other_user}","gists_url":"https://api.github.com/users/farhansyed9/gists{/gist_id}","starred_url":"https://api.github.com/users/farhansyed9/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/farhansyed9/subscriptions","organizations_url":"https://api.github.com/users/farhansyed9/orgs","repos_url":"https://api.github.com/users/farhansyed9/repos","events_url":"https://api.github.com/users/farhansyed9/events{/privacy}","received_events_url":"https://api.github.com/users/farhansyed9/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-06-16T21:56:10Z","updated_at":"2015-06-17T14:21:56Z","closed_at":null,"body":"so i do the command  `createuser -s sales` \r\nand i get this in return \r\n` createuser: creation of new role failed: ERROR:  role \"sales\" already exists `"},"comment":{"url":"https://api.github.com/repos/masteringmodernpayments/book/issues/comments/112821985","html_url":"https://github.com/masteringmodernpayments/book/issues/16#issuecomment-112821985","issue_url":"https://api.github.com/repos/masteringmodernpayments/book/issues/16","id":112821985,"user":{"login":"peterkeen","id":13977,"avatar_url":"https://avatars.githubusercontent.com/u/13977?v=3","gravatar_id":"","url":"https://api.github.com/users/peterkeen","html_url":"https://github.com/peterkeen","followers_url":"https://api.github.com/users/peterkeen/followers","following_url":"https://api.github.com/users/peterkeen/following{/other_user}","gists_url":"https://api.github.com/users/peterkeen/gists{/gist_id}","starred_url":"https://api.github.com/users/peterkeen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/peterkeen/subscriptions","organizations_url":"https://api.github.com/users/peterkeen/orgs","repos_url":"https://api.github.com/users/peterkeen/repos","events_url":"https://api.github.com/users/peterkeen/events{/privacy}","received_events_url":"https://api.github.com/users/peterkeen/received_events","type":"User","site_admin":false},"created_at":"2015-06-17T14:21:56Z","updated_at":"2015-06-17T14:21:56Z","body":"Seems like maybe it has partially run this stuff at least once before. You could try db:reset which will completely destroy and recreate the database. \n\n\n\n> On Jun 16, 2015, at 6:16 PM, farhansyed9 <notifications@github.com> wrote:\n> \n> after i do rails generate devise:install and then run rake db:migrate i get all this:\n> \n> == 20150616221459 DeviseCreateUsers: migrating ================================\n> -- create_table(:users)\n> rake aborted!\n> StandardError: An error has occurred, this and all later migrations canceled:\n> \n> PG::DuplicateTable: ERROR: relation \"users\" already exists\n> : CREATE TABLE \"users\" (\"id\" serial primary key, \"email\" character varying DEFAULT '' NOT NULL, \"encrypted_password\" character varying DEFAULT '' NOT NULL, \"reset_password_token\" character varying, \"reset_password_sent_at\" timestamp, \"remember_created_at\" timestamp, \"sign_in_count\" integer DEFAULT 0 NOT NULL, \"current_sign_in_at\" timestamp, \"last_sign_in_at\" timestamp, \"current_sign_in_ip\" inet, \"last_sign_in_ip\" inet, \"created_at\" timestamp NOT NULL, \"updated_at\" timestamp NOT NULL) /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in async_exec'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:inblock in execute'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract_adapter.rb:473:in block in log'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activesupport-4.2.2/lib/active_support/notifications/instrumenter.rb:20:ininstrument'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract_adapter.rb:467:in log'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:154:inexecute'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/schema_statements.rb:208:in create_table'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:662:inblock in method_missing'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:632:in block in say_with_time'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:632:insay_with_time'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:652:in method_missing'\n> /Users/FarhanSyed/sales/db/migrate/20150616221459_devise_create_users.rb:3:inchange'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:606:in exec_migration'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:590:inblock (2 levels) in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:589:in block in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:292:inwith_connection'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:588:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:765:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:995:in block in execute_migration_in_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:1041:inblock in ddl_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/database_statements.rb:213:in block in transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/transaction.rb:188:inwithin_new_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/database_statements.rb:213:in transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/transactions.rb:220:intransaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:1041:in ddl_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:994:inexecute_migration_in_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:956:in block in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:952:ineach'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:952:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:820:inup'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:798:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/tasks/database_tasks.rb:137:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/railties/databases.rake:44:in block (2 levels) in <top (required)>'\n> ActiveRecord::StatementInvalid: PG::DuplicateTable: ERROR: relation \"users\" already exists\n> : CREATE TABLE \"users\" (\"id\" serial primary key, \"email\" character varying DEFAULT '' NOT NULL, \"encrypted_password\" character varying DEFAULT '' NOT NULL, \"reset_password_token\" character varying, \"reset_password_sent_at\" timestamp, \"remember_created_at\" timestamp, \"sign_in_count\" integer DEFAULT 0 NOT NULL, \"current_sign_in_at\" timestamp, \"last_sign_in_at\" timestamp, \"current_sign_in_ip\" inet, \"last_sign_in_ip\" inet, \"created_at\" timestamp NOT NULL, \"updated_at\" timestamp NOT NULL) \n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:inasync_exec'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in block in execute'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract_adapter.rb:473:inblock in log'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activesupport-4.2.2/lib/active_support/notifications/instrumenter.rb:20:in instrument'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract_adapter.rb:467:inlog'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:154:in execute'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/schema_statements.rb:208:increate_table'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:662:in block in method_missing'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:632:inblock in say_with_time'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:632:in say_with_time'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:652:inmethod_missing'\n> /Users/FarhanSyed/sales/db/migrate/20150616221459_devise_create_users.rb:3:in change'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:606:inexec_migration'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:590:in block (2 levels) in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:589:inblock in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:292:in with_connection'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:588:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:765:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:995:inblock in execute_migration_in_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:1041:in block in ddl_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/database_statements.rb:213:inblock in transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/transaction.rb:188:in within_new_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/database_statements.rb:213:intransaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/transactions.rb:220:in transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:1041:inddl_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:994:in execute_migration_in_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:956:inblock in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:952:in each'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:952:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:820:in up'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:798:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/tasks/database_tasks.rb:137:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/railties/databases.rake:44:inblock (2 levels) in '\n> PG::DuplicateTable: ERROR: relation \"users\" already exists\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:in async_exec'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:155:inblock in execute'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract_adapter.rb:473:in block in log'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activesupport-4.2.2/lib/active_support/notifications/instrumenter.rb:20:ininstrument'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract_adapter.rb:467:in log'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/postgresql/database_statements.rb:154:inexecute'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/schema_statements.rb:208:in create_table'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:662:inblock in method_missing'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:632:in block in say_with_time'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:632:insay_with_time'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:652:in method_missing'\n> /Users/FarhanSyed/sales/db/migrate/20150616221459_devise_create_users.rb:3:inchange'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:606:in exec_migration'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:590:inblock (2 levels) in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:589:in block in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:292:inwith_connection'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:588:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:765:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:995:in block in execute_migration_in_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:1041:inblock in ddl_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/database_statements.rb:213:in block in transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/transaction.rb:188:inwithin_new_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/database_statements.rb:213:in transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/transactions.rb:220:intransaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:1041:in ddl_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:994:inexecute_migration_in_transaction'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:956:in block in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:952:ineach'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:952:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:820:inup'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/migration.rb:798:in migrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/tasks/database_tasks.rb:137:inmigrate'\n> /Users/FarhanSyed/.gem/ruby/2.2.2/gems/activerecord-4.2.2/lib/active_record/railties/databases.rake:44:in `block (2 levels) in '\n> Tasks: TOP => db:migrate\n> (See full trace by running task with --trace)\n> \n> —\n> Reply to this email directly or view it on GitHub.\n> \n"}}