From: Justin Collins Date: 2006-11-06T08:34:29+09:00 Subject: Re: [Fwd: mod_ruby postgres] Parragh Szabolcs wrote: > Hello, > sorry for the repost, but still have no solution, but really would > like to find it:) So could someone please help me a bit -- can I not > extend classes with new methods in mod_ruby? > > -- > > I'm trying some code with mod_ruby where I make a postgresql > connection. The following works fine: > > The latter code works from command line, making the same output as the > first one, however, with mode_ruby I get the following error in apache > error.log: > > [Sat Nov 04 13:28:08 2006] [error] mod_ruby: error in ruby > [Sat Nov 04 13:28:08 2006] [error] mod_ruby: > /var/www/ruby/e1b.rb:20:in `with_db': undefined method `connect' for > #::PGconn (NoMethodError) > > Could someone please help me out with this? It might be an obvious > fault in my code, but I cannot figure it out. > > Thanks: > Szab Try restarting Apache. If you modify a library mod_ruby has already loaded, it won't be reloaded until Apache is restarted. -Justin