From: Brian Candler Date: 2009-07-23T03:49:00+09:00 Subject: Re: uninitialized constant XmlEngine::Logger (NameError) Venkat Akkineni wrote: > Hi > > I am trying to include the log4r gem but the interpreter doesn't seem > to find it it keeps throwing my the following error > >> C:\Users\venkat\Documents\Projects\RuBravo\RubravoCore\lib\XmlEngine>ruby -d XmlEngine.rb > >>Exception `LoadError' at C:/Ruby/lib/ruby/site_ruby/1.8/rubygems.rb:1106 - no >such file to load -- rubygems/defaults/operating_system >>Exception `LoadError' at >C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to >load -- Log4r >>Exception `NameError' at XmlEngine.rb:35 - uninitialized constant >XmlEngine::Logger >>XmlEngine.rb:35: uninitialized constant XmlEngine::Logger (NameError) You are getting confusing output by using ruby -d. Just try ruby, or ruby -w, instead. I can't see your code, but you could try boiling it down to two or three lines which reproduces the problem. It could be that you are simply missing require 'logger' -- Posted via http://www.ruby-forum.com/.