Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > YAML and mod_ruby

Reply
Thread Tools

YAML and mod_ruby

 
 
Hal Fulton
Guest
Posts: n/a
 
      05-20-2004
Here's a small puzzle.

I take a working .rbx and I do a require 'yaml' near the top.

Now it fails.

Error shown below.

Ideas??


Thanks,
Hal



/usr/local/lib/ruby/1.8/date.rb:238: warning: already initialized
constant MONTHNAMES
/usr/local/lib/ruby/1.8/date.rb:243: warning: already initialized
constant DAYNAMES
/usr/local/lib/ruby/1.8/date.rb:247: warning: already initialized
constant ABBR_MONTHNAMES
/usr/local/lib/ruby/1.8/date.rb:250: warning: already initialized
constant ABBR_DAYNAMES
/usr/local/lib/ruby/1.8/date.rb:254: warning: already initialized
constant ITALY
/usr/local/lib/ruby/1.8/date.rb:258: warning: already initialized
constant ENGLAND
/usr/local/lib/ruby/1.8/date.rb:262: warning: already initialized
constant JULIAN
/usr/local/lib/ruby/1.8/date.rb:266: warning: already initialized
constant GREGORIAN
[Thu May 20 10:52:30 2004] [error] mod_ruby: error in ruby
/usr/local/lib/ruby/1.8/date.rb:1259:in `undef_method': undefined method
`today' for `DateTime' (NameError)
from /usr/local/lib/ruby/1.8/date.rb:1259
from /usr/local/lib/ruby/1.8/auto-reload.rb:60:in `load'
from /usr/local/lib/ruby/1.8/auto-reload.rb:60:in `require'
from /usr/local/lib/ruby/1.8/yaml/rubytypes.rb:2
from /usr/local/lib/ruby/1.8/auto-reload.rb:60:in `load'
from /usr/local/lib/ruby/1.8/auto-reload.rb:60:in `require'
from /usr/local/lib/ruby/1.8/yaml.rb:198
from /usr/local/lib/ruby/1.8/auto-reload.rb:60:in `load'
from /usr/local/lib/ruby/1.8/auto-reload.rb:60:in `require'
from /home/hal/www/rubymail/hal/rmail.rbx:21
from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in `load'
from /usr/local/lib/ruby/1.8/apache/ruby-run.rb:70:in `handler'



 
Reply With Quote
 
 
 
 
why the lucky stiff
Guest
Posts: n/a
 
      05-20-2004
Hal Fulton wrote:

> Here's a small puzzle.
>
> I take a working .rbx and I do a require 'yaml' near the top.
>
> Now it fails.


I can't explain exactly why this is happening, but I'm removing the
require 'date' at the top of lib/yaml/rubytypes.rb. This module is
conditionally loaded in ext/syck/rubyext.c now. For now, you should be
able to remove the line and -- though it's hard to say without really
looking into auto-reload.rb -- you should be okay.

_why


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
yaml.rb and YAML "%" directives Joshua Choi Ruby 1 01-14-2007 07:53 AM
Puzzling over why ri can open the std ruby/ri .yaml files, but raw yaml can't Eric Promislow Ruby 4 10-31-2006 10:15 PM
YAML.dump/YAML.load bug Paul Battley Ruby 0 08-03-2005 08:28 PM
rublog and mod_ruby (was: mod_ruby & Apache) Robert McKinnon Ruby 1 03-06-2004 02:29 PM
YAML Question: Using YAML::YamlNode#transform Method to get float values? RubyQuestions Ruby 0 12-03-2003 02:15 AM



Advertisments