NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

A beginner/ Rails version

 
Post new topic   Reply to topic    NetBeans Forums -> Ruby Users
View previous topic :: View next topic  
Author Message
fa00026



Joined: 20 Feb 2009
Posts: 29

PostPosted: Sat Apr 04, 2009 2:34 pm    Post subject: A beginner/ Rails version Reply with quote

The problem is with the new vesrion of Rails is 2.3.2 (the one I have installed after adding Jruby 1.1.6 platform), I do not want this version as I have a project ( the Depot from the ast edition of the book Agile web development with rails) which worked for me before under rails 2.2.2, and is not working under the ne version of Rails (2.3.2 ), I got that message when I first openend the project

Missing the Rails 2.2.2 gem. Please `gem install -v=2.2.2 rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.

So I have fixed this in Config/ enviornment.rb by altering RAILS_GEM_VERSION = '2.2.2' unless defined? RAILS_GEM_VERSION

into

RAILS_GEM_VERSION = '2.3.2' unless defined? RAILS_GEM_VERSION

but my project is not working, once I do Run it shows me nothing no borowser is openend nor any error message. While it was working fluently when I had the prior versin of Rail 2.2.2 so is there a way to downgrade to rails 2.2.2? or any suggetions.

Thanks
Back to top
Erno Mononen
Posted via mailing list.





PostPosted: Sat Apr 04, 2009 6:26 pm    Post subject: A beginner/ Rails version Reply with quote

Hi,

fa00026 wrote:
Quote:
The problem is with the new vesrion of Rails is 2.3.2 (the one I have installed after adding Jruby 1.1.6 platform), I do not want this version as I have a project ( the Depot from the ast edition of the book Agile web development with rails) which worked for me before under rails 2.2.2, and is not working under the ne version of Rails (2.3.2 ), I got that message when I first openend the project



Missing the Rails 2.2.2 gem. Please `gem install -v=2.2.2 rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.



So I have fixed this in Config/ enviornment.rb by altering RAILS_GEM_VERSION = '2.2.2' unless defined? RAILS_GEM_VERSION



into



RAILS_GEM_VERSION = '2.3.2' unless defined? RAILS_GEM_VERSION



but my project is not working, once I do Run it shows me nothing no borowser is openend nor any error message.

This is a known issue with NB 6.5 and Rails 2.3.2 - the browser doesn't
get launched automatically when running the app, but you should still be
able to access the application by just manually entering the address
(likely http://localhost:3000) in the browser.

Quote:
While it was working fluently when I had the prior versin of Rail 2.2.2 so is there a way to downgrade to rails 2.2.2? or any suggetions.


Please see Hassan's reply in case you didn't notice it yet. You can also
remove Rails 2.3.2 and then install 2.2.2 instead in Tools -> Ruby Gems.
Make sure the 'fetch all versions' check box is checked in the settings tab.

HTH,
Erno
Back to top
fa00026



Joined: 20 Feb 2009
Posts: 29

PostPosted: Sun Apr 05, 2009 12:26 am    Post subject: Reply with quote

Hi,

I have uninstalled rails 2.3.2, then installed rails 2.2.2.
And I have also launched to http://localhost:3000 manually, but still no use at all. The project is not running! I wish I can make it run because it will save me so much time rather than rebuilding it.


I appriciate really any advice.

Thanks a lot
Back to top
Erno Mononen
Posted via mailing list.





PostPosted: Mon Apr 06, 2009 7:10 am    Post subject: A beginner/ Rails version Reply with quote

Hi,

fa00026 wrote:
Quote:
Hi,



I have uninstalled rails 2.3.2, then installed rails 2.2.2.

And I have also launched to http://localhost:3000 manually, but still no use at all. The project is not running! I wish I can make it run because it will save me so much time rather than rebuilding it.


What do you get when you go to http://localhost:3000? When you invoke
the Run action, is there anything in the output window or in the log
files (check <project dir>/log/server.log and <project
dir>/log/development.log)?

Erno
Back to top
fa00026



Joined: 20 Feb 2009
Posts: 29

PostPosted: Mon Apr 06, 2009 10:51 am    Post subject: Reply with quote

Thanks for getting back to me,

This is what I get n the output window, and the bowsere never opens:

JRuby limited openssl loaded. gem install jruby-openssl for full support.
=> Booting WEBrick...
http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL
C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:445:in `load_missing_constant': uninitialized constant ActiveRecord::VERSION (NameError)
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:77:in `const_missing_with_dependencies'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activerecord-jdbc-adapter-0.9.1/lib/active_record/connection_adapters/jdbc_adapter.rb:14
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activerecord-jdbc-adapter-0.9.1/lib/active_record/connection_adapters/jdbc_adapter.rb:31:in `require'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:153:in `require'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:521:in `new_constants_in'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:153:in `require'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activerecord-2.2.2/lib/active_record/connection_adapters/abstract/connection_specification.rb:69:in `establish_connection'
... 18 levels...
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/rails-2.2.2/lib/commands/server.rb:31:in `require'
from C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
from script\server:3


Reagrding the files, I have checked the server file it is completely empty. whilke the development file has a lot of text!

Appreciate indeed your help

Thanks
Back to top
Erno Mononen
Posted via mailing list.





PostPosted: Mon Apr 06, 2009 10:57 am    Post subject: A beginner/ Rails version Reply with quote

fa00026 wrote:
Quote:
Thanks for getting back to me,



This is what I get n the output window, and the bowsere never opens:



JRuby limited openssl loaded. gem install jruby-openssl for full support.

=> Booting WEBrick...

http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL

C:/Program Files/NetBeans 6.5/ruby2/jruby-1.1.6/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active_support/dependencies.rb:445:in `load_missing_constant': uninitialized constant ActiveRecord::VERSION (NameError)


Looks like you're hitting a bug in the activerecord-jdbc-adapter 0.9.1
gem (https://kenai.com/jira/browse/ACTIVERECORD_JDBC-9). Please try
downgrading to 0.9, that should help.

Erno
Back to top
fa00026



Joined: 20 Feb 2009
Posts: 29

PostPosted: Mon Apr 06, 2009 12:44 pm    Post subject: Reply with quote

Thanks a milloin, you saved me time and trouble I really apprecaite your fast help.
Back to top
skurt



Joined: 07 Apr 2009
Posts: 2
Location: czech republic

PostPosted: Tue Apr 07, 2009 9:02 pm    Post subject: active record downgrade Reply with quote

Hi,
can someone tell me, how to do it?
Back to top
fa00026



Joined: 20 Feb 2009
Posts: 29

PostPosted: Wed Apr 08, 2009 6:29 pm    Post subject: Reply with quote

If you mean how to do this:


Looks like you're hitting a bug in the activerecord-jdbc-adapter 0.9.1
gem (https://kenai.com/jira/browse/ACTIVERECORD_JDBC-9). Please try
downgrading to 0.9, that should help.


All you need to do is to first uninstall activerecord-jdbc-adapter 0.9.1, then install activerecord-jdbc-adapter from new gems and be sure to choose the vesrion you want.

Tell me if this what you wanted!
Back to top
skurt



Joined: 07 Apr 2009
Posts: 2
Location: czech republic

PostPosted: Wed Apr 08, 2009 10:22 pm    Post subject: active record downgrade Reply with quote

It was the problem...i figured out how to do it and did...
However, the sentence
Missing the Rails 2.3.2 gem. Please `gem install -v=2.3.2 rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.
...is still there.

skurt@need4speed ~ $ rails -v
Rails 2.3.2

In environment I have:
RAILS_GEM_VERSION = '2.3.2' unless defined? RAILS_GEM_VERSION

I really don't know, but I'll bet, its one letter somehow somewhere Sad
Back to top
Brandon Hauff
Posted via mailing list.





PostPosted: Wed Apr 08, 2009 10:47 pm    Post subject: A beginner/ Rails version Reply with quote

You need to use the -v flag to specify the version to install, i.e.

jruby -S gem install activerecord-jdbc-adapter -v=0.9.0

Quote:
-----Original Message-----
From: skurt [mailto:address-removed]
Sent: Wednesday, April 08, 2009 5:22 PM
To: address-removed; address-removed
Subject: A beginner/ Rails version


Sure it is.

I can uninstall the active record gem, but I'm unable to install any
version, but the latest :(









Back to top
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> Ruby Users All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB
By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo