# Is older Ruby versions "looser" than new ones?

**URL:** <https://www.ruby-forum.com/t/is-older-ruby-versions-looser-than-new-ones/104533>\
**Category:** Rails\
**Created:** [May 19, 2007, 1:38am UTC](https://www.ruby-forum.com/t/is-older-ruby-versions-looser-than-new-ones/104533 "2007-05-19T01:38:38Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![SuperRunt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/e36b37/32.png) [@SuperRunt](https://www.ruby-forum.com/u/SuperRunt)\
**Post date:** [May 19, 2007, 1:38am UTC](https://www.ruby-forum.com/t/is-older-ruby-versions-looser-than-new-ones/104533/1 "2007-05-19T01:38:38Z")

</div>

We are trying to get a pre-existing ruby on rails site up and running  
(we just got these files sent to us).

We are new to ruby so we have a new install (we’re running 1.8.6,  
patch level 0).

We have already had to update the code in this app from ‘require\_gem’  
to ‘gem’ and now we are getting variable not initialized errors. We’re  
thinking we’re running a different version of Ruby than where this  
site was hosted before…

Was there a previous ruby version that was by default was loose and  
allowed you ‘spring to life’ variables? Is there a way to tell ruby to  
be loose about its variable declaration?

thanks for the help.

---

<div class="post-metadata">

**Author:** ![SuperRunt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/e36b37/32.png) [@SuperRunt](https://www.ruby-forum.com/u/SuperRunt)\
**Post date:** [May 19, 2007, 7:04pm UTC](https://www.ruby-forum.com/t/is-older-ruby-versions-looser-than-new-ones/104533/2 "2007-05-19T19:04:04Z")

</div>

SuperRunt wrote:

> Was there a previous ruby version that was by default was loose and  
> allowed you ‘spring to life’ variables? Is there a way to tell ruby to  
> be loose about its variable declaration?

[http://groups.google.ca/group/rubyonrails-talk/browse\_thread/thread/b17aa16b770cf025/59ac13552bab9c09?lnk=raot](http://groups.google.ca/group/rubyonrails-talk/browse_thread/thread/b17aa16b770cf025/59ac13552bab9c09?lnk=raot)

In short:

require\_gem was used to both define a version of a gem and require it.

This is now deprecated.

To define the version of a gem you use ‘gem’.

To actually require the file you need to use ‘require’.

If you want the latest version ‘require’ will be enough.

Stefan

---

<div class="post-metadata">

**Author:** ![SuperRunt](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/e36b37/32.png) [@SuperRunt](https://www.ruby-forum.com/u/SuperRunt)\
**Post date:** [May 19, 2007, 6:11am UTC](https://www.ruby-forum.com/t/is-older-ruby-versions-looser-than-new-ones/104533/3 "2007-05-19T06:11:54Z")

</div>

What are the warnings that you’re receiving? It’s probable that  
you’re running ruby with the -w switch on. Rails wasn’t written to be  
-w clean, so make sure you take that switch off. If you can’t control  
the command line switch, you can force it by setting $VERBOSE to nil  
or false in your config/environment.rb.
