Skip to content

Instantly share code, notes, and snippets.

@jamland
Created September 16, 2013 19:07
Show Gist options
  • Save jamland/6585071 to your computer and use it in GitHub Desktop.
Save jamland/6585071 to your computer and use it in GitHub Desktop.
rake aborted!
An error has occurred, all later migrations canceled:
Mysql2::Error: Duplicate entry '90234-82524' for key 'index_project_memberships_on_user_id_and_project_id': CREATE UNIQUE INDEX `index_project_memberships_on_user_id_and_project_id` ON `project_memberships` (`user_id`, `project_id`)/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:245:in `query'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:245:in `block in execute'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_adapter.rb:280:in `block in log'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activesupport-3.2.13/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_adapter.rb:275:in `log'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract_mysql_adapter.rb:245:in `execute'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/mysql2_adapter.rb:211:in `execute'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract/schema_statements.rb:352:in `add_index'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:466:in `block in method_missing'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:438:in `block in say_with_time'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:438:in `say_with_time'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:458:in `method_missing'
/Users/andy/Sites/repository/airbrake-app/db/migrate/20130827141436_add_unique_constraint_on_p_ms.rb:4:in `up'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:410:in `block (2 levels) in migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:410:in `block in migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/connection_adapters/abstract/connection_pool.rb:129:in `with_connection'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:389:in `migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:528:in `migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:720:in `block (2 levels) in migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:777:in `call'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:777:in `ddl_transaction'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:719:in `block in migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:700:in `each'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:700:in `migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:570:in `up'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/migration.rb:551:in `migrate'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/gems/activerecord-3.2.13/lib/active_record/railties/databases.rake:193:in `block (2 levels) in <top (required)>'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/bin/ruby_noexec_wrapper:14:in `eval'
/Users/andy/.rvm/gems/ruby-2.0.0-p247@airbrake/bin/ruby_noexec_wrapper:14:in `<main>'
Tasks: TOP => db:migrate
(See full trace by running task with --trace)
Intergalactic:airbrake-app andy$ touch tmp/restart.txt
Intergalactic:airbrake-app andy$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment