Skip to content


Fixes arity problem introduced by rails 3.2.5 #1

wants to merge 2 commits into from

2 participants


Rails 3.2.5 changed the arity of a method you're alias_method_chaining. This patch corrects that. Sadly, this doesn't seem to be exercised by the test suite anywhere, but I can verify it was broken, and now works, when integrated with a real-world app. :)

@metaskills metaskills added a commit that closed this pull request
@metaskills Fixes arity problem introduced by rails 3.2.5. Fixes #1
* Also master is now 3.2 only.

So odd, the test suite does exercise that method because if you comment out the guts, one fails. Odd. I've pushed v3.2.0 with this. Thanks.

@metaskills metaskills reopened this

Had to be persnickety and make the arg name match. No need to upgrade, but 3.2.1 is out.

@metaskills metaskills closed this

Our future selves appreciate your careful attention to detail; names are important. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jun 11, 2012
  1. @dball

    Updates to rails 3.2.5

    dball committed
  2. @dball
Showing with 4 additions and 4 deletions.
  1. +1 −1 Gemfile
  2. +1 −1 Gemfile.rails-3.2
  3. +2 −2 lib/grouped_scope/arish/relation/predicate_builer.rb
2 Gemfile
@@ -1 +1 @@
2 Gemfile.rails-3.2
@@ -6,4 +6,4 @@ deps = { |dep| {:name =>, :version => dep.require
deps.reject! { |dep| dep[:name] =~ /activerecord/ }
deps.each { |dep| gem dep[:name], dep[:version] }
-gem 'activerecord', '3.2.0.rc1'
+gem 'activerecord', '3.2.5'
4 lib/grouped_scope/arish/relation/predicate_builer.rb
@@ -10,12 +10,12 @@ module PredicateBuilder
module ClassMethods
- def build_from_hash_with_grouped_scope(engine, attributes, default_table)
+ def build_from_hash_with_grouped_scope(engine, attributes, default_table, check_column = true){ |column, value| GroupedScope::SelfGroupping === value }.each do |column_value|
column, value = column_value
attributes[column] = value.arel_table[column.to_s].in(value.ids_sql)
- build_from_hash_without_grouped_scope(engine, attributes, default_table)
+ build_from_hash_without_grouped_scope(engine, attributes, default_table, check_column)
Something went wrong with that request. Please try again.