title: Rails: rake db:migrate -> stack level too deep
body: <p>I've never seen this error before, and I've no idea what I should be looking for.</p>
  
  <pre><code>$ rake db:migrate --trace
  (in /Users/tscolari/Projetos/movies)
  ** Invoke db:migrate (first_time)
  ** Invoke environment (first_time)
  ** Execute environment
  ** Execute db:migrate
  rake aborted!
  stack level too deep
  /opt/local/lib/ruby/gems/1.8/gems/scrubyt-0.4.06/lib/scrubyt/utils/ruby_extensions.rb:66:in `write'
  /opt/local/lib/ruby/gems/1.8/gems/scrubyt-0.4.06/lib/scrubyt/utils/ruby_extensions.rb:66:in `collect'
  /opt/local/lib/ruby/gems/1.8/gems/scrubyt-0.4.06/lib/scrubyt/utils/ruby_extensions.rb:66:in `write'
  /opt/local/lib/ruby/gems/1.8/gems/scrubyt-0.4.06/lib/scrubyt/utils/ruby_extensions.rb:66:in `write'
  /opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/buffered_logger.rb:108:in `flush'
  /opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/buffered_logger.rb:101:in `synchronize'
  /opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/buffered_logger.rb:101:in `flush'
  /opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/buffered_logger.rb:125:in `auto_flush'
  /opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/buffered_logger.rb:66:in `add'
  /opt/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/buffered_logger.rb:77:in `debug'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/connection_adapters/abstract_adapter.rb:201:in `log'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/connection_adapters/sqlite_adapter.rb:135:in `execute'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/connection_adapters/sqlite_adapter.rb:180:in `tables'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/connection_adapters/abstract/schema_statements.rb:21:in `table_exists?'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/connection_adapters/abstract/schema_statements.rb:429:in `initialize_schema_migrations_table'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/migration.rb:487:in `initialize'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/migration.rb:433:in `new'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/migration.rb:433:in `up'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/migration.rb:415:in `migrate'
  /opt/local/lib/ruby/gems/1.8/gems/activerecord-3.0.0/lib/active_record/railties/databases.rake:142
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `call'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:636:in `execute'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `each'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:631:in `execute'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:597:in `invoke_with_call_chain'
  /opt/local/lib/ruby/1.8/monitor.rb:242:in `synchronize'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:590:in `invoke_with_call_chain'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:583:in `invoke'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2051:in `invoke_task'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `top_level'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `each'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2029:in `top_level'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in `standard_exception_handling'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2023:in `top_level'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2001:in `run'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2068:in `standard_exception_handling'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:1998:in `run'
  /opt/local/lib/ruby/gems/1.8/gems/rake-0.8.7/bin/rake:31
  /opt/local/bin/rake:19:in `load'
  /opt/local/bin/rake:19
  </code></pre>
  
  <p>First I thought it could be something wrong in one of my migrations, so I removed them all to check, and the error still.
  And strangely the application/console starts without any problem:</p>
  
  <pre><code>$ rails server
  =&gt; Booting Mongrel
  =&gt; Rails 3.0.0 application starting in development on http://0.0.0.0:3000
  =&gt; Call with -d to detach
  =&gt; Ctrl-C to shutdown server
  </code></pre>
  
  <p>And then I have no idea where to look for the error. Any help?</p>