New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incompatibility with Rails 4.rc1 #5

Open
chatgris opened this Issue May 2, 2013 · 7 comments

Comments

Projects
None yet
6 participants
@chatgris

chatgris commented May 2, 2013

Hello,

I ran across an issue while upgrading to rails 4.rc1.

wrong number of arguments (1 for 4)
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/connection_adapters/abstract/schema_definitions.rb:54:in `initialize'
/home/chatgris/dev/oss/activerecord-postgresql-extensions/lib/active_record/postgresql_extensions/tables.rb:180:in `initialize'
/home/chatgris/dev/oss/activerecord-postgresql-extensions/lib/active_record/postgresql_extensions/tables.rb:109:in `new'
/home/chatgris/dev/oss/activerecord-postgresql-extensions/lib/active_record/postgresql_extensions/tables.rb:109:in `create_table'
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/schema_migration.rb:21:in `create_table'
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/migration.rb:857:in `initialize'
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/migration.rb:747:in `new'
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/migration.rb:747:in `up'
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/migration.rb:725:in `migrate'
/home/chatgris/.gem/ruby/2.0.0/gems/activerecord-4.0.0.rc1/lib/active_record/railties/databases.rake:42:in `block (2 levels) in <top (required)>'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:246:in `call'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:246:in `block in execute'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:241:in `each'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:241:in `execute'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:184:in `block in invoke_with_call_chain'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:177:in `invoke_with_call_chain'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/task.rb:170:in `invoke'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:143:in `invoke_task'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:101:in `block (2 levels) in top_level'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:101:in `each'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:101:in `block in top_level'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:110:in `run_with_threads'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:95:in `top_level'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:73:in `block in run'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:160:in `standard_exception_handling'
/home/chatgris/.gem/ruby/2.0.0/gems/rake-10.0.4/lib/rake/application.rb:70:in `run'
Tasks: TOP => db:migrate

I dug a little, and this seems to be related to some refactoring into ActiveRecord, TableDefinition no longer receive the connector object.

I tried to modify the initialize method to match the one from AR, but there are some other breaking changes.

Check out rails/rails@14d7dc0 , rails/rails@a80bcc3 or rails/rails@b8a533d for example.

@dark-panda

This comment has been minimized.

Owner

dark-panda commented Jun 3, 2013

We're planning on a new release once Rails 4 is out. We've just been working out the Rails 4 fixes. There's still so many changes going on with Rails 4 that it's hard to pin down an exact date, but once Rails 4 final comes out and things are stable, we'll be releasing a new gem with all of the fixes in place. I've done a few of the changes already, but need some time to look at the schema creation changes and work them in with our extensions.

@mhenrixon

This comment has been minimized.

mhenrixon commented Nov 28, 2013

👍

@jtarchie

This comment has been minimized.

jtarchie commented Jan 15, 2014

How about it?

@ukd1

This comment has been minimized.

ukd1 commented Feb 5, 2014

👍

@mhenrixon

This comment has been minimized.

mhenrixon commented Feb 5, 2014

Come on guys, rails 4 has been out for some time... 👍

@dark-panda

This comment has been minimized.

Owner

dark-panda commented Feb 5, 2014

Could anyone with Rails 4 issues please give the rails-4 branch a test run? We haven't had the time to upgrade our own applications to Rails 4 yet, but I have refactored rails-4 branch that Works For Me(tm) in Rails 3.2 and 4.0.2 as far as the unit tests are concerned. If we get some positive feedback that things are actually running correctly outside of the unit tests then we should be able to do a release. (Our internal migration to Rails 4 has taken a lot longer than expected, so Rails 4 testing has been slow going, and thus we haven't had the time to do a real world test on this gem. :/ )

@mavenik

This comment has been minimized.

mavenik commented Jul 18, 2014

Tried rails-4 branch in one of my Rails projects. Worked for me on Rails 4.1.4.
Features used:

  • :inherits
  • t.unique_constraint
  • :references
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment