Ruby + yaml = warnings???

Discussion in 'Ruby' started by Kurt V. Hindenburg, Dec 12, 2005.

  1. % ruby --version
    ruby 1.8.3 (2005-09-21) [i686-linux]

    % cat a.rb
    require 'yaml'

    o = [ 'array', 'of', 'items' ]
    o2 = YAML::load( o.to_yaml )

    % ruby -w a.rb
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):14: warning: redefine yaml_tag_subclasses?
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):14: warning: redefine yaml_tag_subclasses?
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):14: warning: redefine yaml_tag_subclasses?
    (eval):2: warning: method redefined; discarding old taguri
    (eval):14: warning: redefine yaml_tag_subclasses?
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):14: warning: redefine yaml_tag_subclasses?
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):14: warning: redefine yaml_tag_subclasses?
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    /usr/lib/ruby/1.8/yaml/types.rb:13: warning: method redefined; discarding old
    initialize
    /usr/lib/ruby/1.8/yaml/types.rb:28: warning: method redefined; discarding old
    initialize
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):2: warning: method redefined; discarding old taguri
    (eval):6: warning: instance variable @taguri not initialized
    (eval):6: warning: instance variable @taguri not initialized
    (eval):6: warning: instance variable @taguri not initialized
    (eval):6: warning: instance variable @taguri not initialized
    /usr/lib/ruby/1.8/yaml.rb:133: warning: instance variable @input not
    initialized
    Kurt V. Hindenburg, Dec 12, 2005
    #1
    1. Advertising

  2. FYI, no warnings in 1.8.2

    On Dec 11, 2005, at 9:22 PM, Kurt V. Hindenburg wrote:

    >
    > % ruby --version
    > ruby 1.8.3 (2005-09-21) [i686-linux]
    >
    > % cat a.rb
    > require 'yaml'
    >
    > o = [ 'array', 'of', 'items' ]
    > o2 = YAML::load( o.to_yaml )
    >
    > % ruby -w a.rb
    > (eval):2: warning: method redefined; discarding old taguri
    > (eval):2: warning: method redefined; discarding old taguri
    > (eval):2: warning: method redefined; discarding old taguri


    ----
    Bob Hutchison -- blogs at <http://www.recursive.ca/hutch/>
    Recursive Design Inc. -- <http://www.recursive.ca/>
    Raconteur -- <http://www.raconteur.info/>
    Bob Hutchison, Dec 12, 2005
    #2
    1. Advertising

  3. Bob Hutchison wrote:
    > FYI, no warnings in 1.8.2
    >
    > On Dec 11, 2005, at 9:22 PM, Kurt V. Hindenburg wrote:


    I played around with yaml on 1.8.3 and found out it is completely broken
    (doesn't put --- before objects, misses returns). If you want to use
    yaml you should upgrade to a 1.8.4 beta or downgrade to 1.8.2

    --
    Posted via http://www.ruby-forum.com/.
    Edwin van Leeuwen, Dec 12, 2005
    #3
  4. Edwin van Leeuwen wrote:
    > Bob Hutchison wrote:
    >> FYI, no warnings in 1.8.2
    >>
    >> On Dec 11, 2005, at 9:22 PM, Kurt V. Hindenburg wrote:

    >
    > I played around with yaml on 1.8.3 and found out it is completely broken
    > (doesn't put --- before objects, misses returns). If you want to use
    > yaml you should upgrade to a 1.8.4 beta or downgrade to 1.8.2

    yaml seems to be broken on 1.8.4_pre2 too, so I suggest downgrading to
    1.8.2

    --
    Posted via http://www.ruby-forum.com/.
    Edwin van Leeuwen, Dec 12, 2005
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. RubyQuestions
    Replies:
    0
    Views:
    220
    RubyQuestions
    Dec 3, 2003
  2. Daniel Berger

    Gem and/or YAML warnings

    Daniel Berger, Jun 17, 2005, in forum: Ruby
    Replies:
    1
    Views:
    119
    Chad Fowler
    Jun 18, 2005
  3. Paul Battley

    YAML.dump/YAML.load bug

    Paul Battley, Aug 3, 2005, in forum: Ruby
    Replies:
    0
    Views:
    176
    Paul Battley
    Aug 3, 2005
  4. Eric Promislow
    Replies:
    4
    Views:
    207
    Eric Promislow
    Oct 31, 2006
  5. Ted Sung
    Replies:
    1
    Views:
    308
    Sherm Pendley
    Aug 30, 2004
Loading...

Share This Page