re:Problems with sqllite with fresh Rails 3 install

Ok, I’ve narrowed it down to line 70 of connection_specification:

gem “activerecord-#{spec[:adapter]}-adapter”

It’s evaluating to the correct adapter -
activerecord-jdbcsqlite3-adapter, but for some reason it throws a
LoadError.

Loading the same library seems to work:
csevans$ jruby -e ‘require “rubygems”; gem
“activerecord-jdbcsqlite3-adapter”’
csevans$

Any thoughts on why Rails won’t load the correct adapter?


Chris


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

That’s odd…can you try running with -w and/or -d to see if there’s
any errors getting swallowed?

On Thu, Mar 25, 2010 at 12:28 PM, Chris E. [email protected]
wrote:

 csevans$
  http://xircles.codehaus.org/manage_email


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Hi Chris,

csevans$ jruby -e ‘require “rubygems”; gem “activerecord-jdbcsqlite3-adapter”’
csevans$

Any thoughts on why Rails won’t load the correct adapter?


Chris

Sorry to butt in, however, I had a similar problem with JRuby, Rails3
and
sqlite3 as well. I got round it by changing this line in Gemfile -

gem ‘activerecord-jdbc-adapter’, :require => false

to

gem ‘activerecord-jdbcsqlite3-adapter’, :require => false

HTH.

Regards,

Chris


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

On Sat, Mar 27, 2010 at 11:20 AM, Chris D. [email protected]
wrote:

Sorry to butt in, however, I had a similar problem with JRuby, Rails3 and
sqlite3 as well. I got round it by changing this line in Gemfile -

gem ‘activerecord-jdbc-adapter’, :require => false

to

gem ‘activerecord-jdbcsqlite3-adapter’, :require => false

With the http://jruby.org/rails3.rb template, you should be using
“adapter: sqlite3” in database.yml, not “adapter: jdbcsqlite3”. If you
still want to use the jdbc- prefix, then you will need this change in
your Gemfile.

/Nick


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email

Hi Nick,

On 28 Mar 2010, at 21:17, Nick S. wrote:

activerecord-jdbcsqlite3-adapter, but for some reason it throws a
Chris
gem ‘activerecord-jdbcsqlite3-adapter’, :require => false

With the http://jruby.org/rails3.rb template, you should be using
“adapter: sqlite3” in database.yml, not “adapter: jdbcsqlite3”. If you
still want to use the jdbc- prefix, then you will need this change in
your Gemfile.

/Nick

I’ve just tried to recreate the problem and can’t. I could have sworn
that I didn’t change anything until I got an error message.
Nonetheless, everything is working for me now as your blog post
describes, so thank you.

Regards,

Chris


To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email