title: What's the Rails 3 replacement for ActiveRecord::Errors?
body: <p>What's the Rails 3 replacement for ActiveRecord::Errors?</p>
  
  <p>In Rails 2.3.8, this is an object:</p>
  
  <pre><code>&gt;&gt; ActiveRecord::Errors
  =&gt; ActiveRecord::Errors
  </code></pre>
  
  <p>In Rails 3.0.0rc, you get a NameError:</p>
  
  <pre><code>&gt;&gt; ActiveRecord::Errors
  NameError: uninitialized constant ActiveRecord::Errors
   from (irb):2
  </code></pre>
  
  <p>I'm trying to make the <a href="http://github.com/gaveeno/wizardly" rel="noreferrer">wizardly</a> generator work with Rails 3. </p>
  
  <pre><code>$ rails g wizardly_scaffold home
  </code></pre>
  
  <p>But it fails:</p>
  
  <pre><code>/Library/Ruby/Gems/1.8/gems/wizardly_gt-0.1.8.9/lib/validation_group.rb:150:
  uninitialized constant ActiveRecord::Errors (NameError)
  </code></pre>
  
  <p>The line it refers to is this:</p>
  
  <pre><code>ActiveRecord::Errors.send :include, ValidationGroup::ActiveRecord::Errors
  </code></pre>
  
  <p>Earlier in the file, we see:</p>
  
  <pre><code>module ValidationGroup
    module ActiveRecord
  ...
      module Errors # included in ActiveRecord::Errors
        def add_with_validation_group(attribute, msg = I18n.translate('activerecord.errors.messages')[:invalid], *args, &amp;block)
          add_error = @base.respond_to?(:should_validate?) ? (@base.should_validate?(attribute.to_sym) || attribute == :base) : true
          add_without_validation_group(attribute, msg, *args, &amp;block) if add_error
        end
  ...
  end
  </code></pre>