RedCloth .... PILES of warnings when I require it ...

Discussion in 'Ruby' started by Jeff Wood, Aug 19, 2005.

  1. Jeff Wood

    Jeff Wood Guest

    --------------030304030306010402010005
    Content-Type: text/plain; charset=ISO-8859-1; format=flowed
    Content-Transfer-Encoding: 7bit

    I've downloaded and have the Gem for RedCloth 3.0.3 installed.

    When I require it ( after require 'rubygems' ) I get a PILE of warning
    messages about constants that are already defined ...

    Anybody have any input on this?

    I'd love to have a quiet this stuff down...

    j.

    --------------030304030306010402010005--
     
    Jeff Wood, Aug 19, 2005
    #1
    1. Advertising

  2. Jeff Wood wrote:

    > I've downloaded and have the Gem for RedCloth 3.0.3 installed.
    >
    > When I require it ( after require 'rubygems' ) I get a PILE of warning
    > messages about constants that are already defined ...
    >
    > Anybody have any input on this?
    >
    > I'd love to have a quiet this stuff down...
    >
    > j.
    >

    Comstants? Strange...
    This is what I get:

    C:\instiki>ruby -w -e "require 'redcloth'"
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:612:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:832:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:1037:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:815:
    warning: method redefined; discarding old inline_markdown_link

    same with require_gem 'RedCloth'

    Alex
     
    Alex Verhovsky, Aug 19, 2005
    #2
    1. Advertising

  3. Jeff Wood

    Jeff Wood Guest

    --------------060009010708030307010402
    Content-Type: text/plain; charset=ISO-8859-1; format=flowed
    Content-Transfer-Encoding: 7bit

    Alex Verhovsky wrote:

    > Jeff Wood wrote:
    >
    >> I've downloaded and have the Gem for RedCloth 3.0.3 installed.
    >>
    >> When I require it ( after require 'rubygems' ) I get a PILE of
    >> warning messages about constants that are already defined ...
    >>
    >> Anybody have any input on this?
    >>
    >> I'd love to have a quiet this stuff down...
    >>
    >> j.
    >>

    > Comstants? Strange...
    > This is what I get:
    >
    > C:\instiki>ruby -w -e "require 'redcloth'"
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:612:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:832:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:1037:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:815:
    > warning: method redefined; discarding old inline_markdown_link
    >
    > same with require_gem 'RedCloth'
    >
    > Alex
    >
    >
    >

    I'm getting:

    irb(main):001:0> require 'RedCloth'
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:169:
    warning: already initialized constant VERSION
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:170:
    warning: already initialized constant DEFAULT_RULES
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:311:
    warning: already initialized constant TEXTILE_TAGS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:324:
    warning: already initialized constant A_HLGN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:325:
    warning: already initialized constant A_VLGN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:326:
    warning: already initialized constant C_CLAS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:327:
    warning: already initialized constant C_LNGE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:328:
    warning: already initialized constant C_STYL
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:329:
    warning: already initialized constant S_CSPN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:330:
    warning: already initialized constant S_RSPN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:331:
    warning: already initialized constant A
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:332:
    warning: already initialized constant S
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:333:
    warning: already initialized constant C
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:335:
    warning: already initialized constant PUNCT
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:336:
    warning: already initialized constant HYPERLINK
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:342:
    warning: already initialized constant SIMPLE_HTML_TAGS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:364:
    warning: already initialized constant GLYPHS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:371:
    warning: already initialized constant H_ALGN_VALS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:377:
    warning: already initialized constant V_ALGN_VALS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:390:
    warning: already initialized constant QTAGS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:475:
    warning: already initialized constant TABLE_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:513:
    warning: already initialized constant LISTS_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:514:
    warning: already initialized constant LISTS_CONTENT_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:565:
    warning: already initialized constant CODE_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:583:
    warning: already initialized constant BLOCKS_GROUP_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:655:
    warning: already initialized constant BLOCK_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:671:
    warning: already initialized constant SETEXT_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:686:
    warning: already initialized constant ATX_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:696:
    warning: already initialized constant MARKDOWN_BQ_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:709:
    warning: already initialized constant MARKDOWN_RULE_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:749:
    warning: already initialized constant LINK_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:781:
    warning: already initialized constant MARKDOWN_REFLINK_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:813:
    warning: already initialized constant MARKDOWN_LINK_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:827:
    warning: already initialized constant TEXTILE_REFS_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:828:
    warning: already initialized constant MARKDOWN_REFS_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:868:
    warning: already initialized constant IMAGE_RE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:961:
    warning: already initialized constant OFFTAGS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:962:
    warning: already initialized constant OFFTAG_MATCH
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:963:
    warning: already initialized constant OFFTAG_OPEN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:964:
    warning: already initialized constant OFFTAG_CLOSE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:965:
    warning: already initialized constant HASTAG_MATCH
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:966:
    warning: already initialized constant ALLTAG_MATCH
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:1085:
    warning: already initialized constant BASIC_TAGS
    => true
    irb(main):002:0>

    ... I get these same errors in my output when I do the require from a
    script instead of IRB ... I'd LOVE to see these go away...

    As far as environment specifics ... I'm running Ruby for Windows (
    one-click 1.8.2 - 15 ) ... and I used Gem to install RedCloth ( version
    3.0.3 )

    So, if ANYBODY can provide a bit of information to help get rid of
    these, I'd really appreciate it.

    j.


    --------------060009010708030307010402--
     
    Jeff Wood, Aug 19, 2005
    #3
  4. Jeff Wood

    Jeff Wood Guest

    --------------010308030004050002050802
    Content-Type: text/plain; charset=ISO-8859-1; format=flowed
    Content-Transfer-Encoding: 7bit

    Jeff Wood wrote:

    > Alex Verhovsky wrote:
    >
    >> Jeff Wood wrote:
    >>
    >>> I've downloaded and have the Gem for RedCloth 3.0.3 installed.
    >>>
    >>> When I require it ( after require 'rubygems' ) I get a PILE of
    >>> warning messages about constants that are already defined ...
    >>>
    >>> Anybody have any input on this?
    >>>
    >>> I'd love to have a quiet this stuff down...
    >>>
    >>> j.
    >>>

    >> Comstants? Strange...
    >> This is what I get:
    >>
    >> C:\instiki>ruby -w -e "require 'redcloth'"
    >> c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:612:
    >> warning: ambiguous first argument; put parentheses or even spaces
    >> c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:832:
    >> warning: ambiguous first argument; put parentheses or even spaces
    >> c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:1037:
    >> warning: ambiguous first argument; put parentheses or even spaces
    >> c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:815:
    >> warning: method redefined; discarding old inline_markdown_link
    >>
    >> same with require_gem 'RedCloth'
    >>
    >> Alex
    >>
    >>
    >>

    > I'm getting:
    >
    > irb(main):001:0> require 'RedCloth'
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:169:
    > warning: already initialized constant VERSION
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:170:
    > warning: already initialized constant DEFAULT_RULES
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:311:
    > warning: already initialized constant TEXTILE_TAGS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:324:
    > warning: already initialized constant A_HLGN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:325:
    > warning: already initialized constant A_VLGN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:326:
    > warning: already initialized constant C_CLAS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:327:
    > warning: already initialized constant C_LNGE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:328:
    > warning: already initialized constant C_STYL
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:329:
    > warning: already initialized constant S_CSPN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:330:
    > warning: already initialized constant S_RSPN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:331:
    > warning: already initialized constant A
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:332:
    > warning: already initialized constant S
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:333:
    > warning: already initialized constant C
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:335:
    > warning: already initialized constant PUNCT
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:336:
    > warning: already initialized constant HYPERLINK
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:342:
    > warning: already initialized constant SIMPLE_HTML_TAGS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:364:
    > warning: already initialized constant GLYPHS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:371:
    > warning: already initialized constant H_ALGN_VALS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:377:
    > warning: already initialized constant V_ALGN_VALS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:390:
    > warning: already initialized constant QTAGS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:475:
    > warning: already initialized constant TABLE_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:513:
    > warning: already initialized constant LISTS_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:514:
    > warning: already initialized constant LISTS_CONTENT_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:565:
    > warning: already initialized constant CODE_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:583:
    > warning: already initialized constant BLOCKS_GROUP_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:655:
    > warning: already initialized constant BLOCK_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:671:
    > warning: already initialized constant SETEXT_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:686:
    > warning: already initialized constant ATX_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:696:
    > warning: already initialized constant MARKDOWN_BQ_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:709:
    > warning: already initialized constant MARKDOWN_RULE_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:749:
    > warning: already initialized constant LINK_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:781:
    > warning: already initialized constant MARKDOWN_REFLINK_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:813:
    > warning: already initialized constant MARKDOWN_LINK_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:827:
    > warning: already initialized constant TEXTILE_REFS_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:828:
    > warning: already initialized constant MARKDOWN_REFS_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:868:
    > warning: already initialized constant IMAGE_RE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:961:
    > warning: already initialized constant OFFTAGS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:962:
    > warning: already initialized constant OFFTAG_MATCH
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:963:
    > warning: already initialized constant OFFTAG_OPEN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:964:
    > warning: already initialized constant OFFTAG_CLOSE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:965:
    > warning: already initialized constant HASTAG_MATCH
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:966:
    > warning: already initialized constant ALLTAG_MATCH
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:1085:
    > warning: already initialized constant BASIC_TAGS
    > => true
    > irb(main):002:0>
    >
    > ... I get these same errors in my output when I do the require from a
    > script instead of IRB ... I'd LOVE to see these go away...
    >
    > As far as environment specifics ... I'm running Ruby for Windows (
    > one-click 1.8.2 - 15 ) ... and I used Gem to install RedCloth (
    > version 3.0.3 )
    >
    > So, if ANYBODY can provide a bit of information to help get rid of
    > these, I'd really appreciate it.
    >
    > j.
    >
    >

    Reading your mail further, I tried the same using require_gem
    'RedCloth' and don't get all of those messages, why should that make a
    difference?

    j.


    --------------010308030004050002050802--
     
    Jeff Wood, Aug 19, 2005
    #4
  5. --Apple-Mail-1-94629694
    Content-Transfer-Encoding: 7bit
    Content-Type: text/plain;
    charset=US-ASCII;
    delsp=yes;
    format=flowed

    On Aug 18, 2005, at 11:29 PM, Jeff Wood wrote:
    > Reading your mail further, I tried the same using require_gem
    > 'RedCloth' and don't get all of those messages, why should that
    > make a difference?


    I'm guessing that you have redcloth installed both as a gem and as a
    library, and that it is being required from both locations, and the
    second require is redefining the constants. Guessing. Heavily.

    --Apple-Mail-1-94629694--
     
    Gavin Kistner, Aug 19, 2005
    #5
  6. Gavin Kistner wrote:

    > On Aug 18, 2005, at 11:29 PM, Jeff Wood wrote:
    >
    >> Reading your mail further, I tried the same using require_gem
    >> 'RedCloth' and don't get all of those messages, why should that make
    >> a difference?

    >
    >
    > I'm guessing that you have redcloth installed both as a gem and as a
    > library, and that it is being required from both locations, and the
    > second require is redefining the constants. Guessing. Heavily.
    >

    Aha! I know, I know! Case-insensitive Windows file system strikes again,
    and this time it bites RubyGems in the stern. Amusing :)

    try require'redcloth' instead (note the lower case!), and see for yourself.

    This is a RubyGems bug. To reproduce:

    1. Take fresh Ruby install (must be on Windows)
    2. Install RubyGems
    3. Install RedCloth by gem install redcloth
    4. Modify \ruby\lib\ruby\gems\1.8\gems\RedCloth3.0.3\redcloth.rb by
    adding puts 'HERE' in the beginning.
    5. ruby -w -e "require 'RedCloth'"

    C:\>ruby -w -e "require 'RedCloth'"
    HERE
    HERE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:612:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:832:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:1037:
    warning: amiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:815:
    warning: method redefined; discarding old inline_markdown_link
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:612:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:832:
    warning: ambiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:1037:
    warning: amiguous first argument; put parentheses or even spaces
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:169:
    warning: already initialized constant VERSION
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:170:
    warning: already initialized constant DEFAULT_RULES
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:242:
    warning: metod redefined; discarding old initialize
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:254:
    warning: metod redefined; discarding old to_html
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:311:
    warning: already initialized constant TEXTILE_TAGS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:324:
    warning: already initialized constant A_HLGN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:325:
    warning: already initialized constant A_VLGN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:326:
    warning: already initialized constant C_CLAS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:327:
    warning: already initialized constant C_LNGE
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:328:
    warning: already initialized constant C_STYL
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:329:
    warning: already initialized constant S_CSPN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:330:
    warning: already initialized constant S_RSPN
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:331:
    warning: already initialized constant A
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:332:
    warning: already initialized constant S
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:333:
    warning: already initialized constant C
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:335:
    warning: already initialized constant PUNCT
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:336:
    warning: already initialized constant HYPERLINK
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:342:
    warning: already initialized constant SIMPLE_HTML_TAGS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:364:
    warning: already initialized constant GLYPHS
    c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:371:
    warning: alre
    this causes redcloth.rb to be loaded twice - first from ruby/lib/

    Alex
     
    Alexey Verkhovsky, Aug 19, 2005
    #6
  7. Jeff Wood

    Krishna Dole Guest

    I get the same double-load on Mac OS 10.3.9:

    $ ruby -w -e "require 'rubygems'; require 'RedCloth'"
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:612:
    warning: ambiguous first argument; put parentheses or even spaces
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:832:
    warning: ambiguous first argument; put parentheses or even spaces
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:1037:
    warning: ambiguous first argument; put parentheses or even spaces
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:815:
    warning: method redefined; discarding old inline_markdown_link
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:612:
    warning: ambiguous first argument; put parentheses or even spaces
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:832:
    warning: ambiguous first argument; put parentheses or even spaces
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:1037:
    warning: ambiguous first argument; put parentheses or even spaces
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:169:
    warning: already initialized constant VERSION
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:170:
    warning: already initialized constant DEFAULT_RULES
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:242:
    warning: method redefined; discarding old initialize
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:254:
    warning: method redefined; discarding old to_html
    /usr/local/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:311:
    warning: already initialized constant TEXTILE_TAGS
    -- (and so on) --=20

    Krishna

    On 8/19/05, Alexey Verkhovsky <> wrote:
    > Gavin Kistner wrote:
    >=20
    > > On Aug 18, 2005, at 11:29 PM, Jeff Wood wrote:
    > >
    > >> Reading your mail further, I tried the same using require_gem
    > >> 'RedCloth' and don't get all of those messages, why should that make
    > >> a difference?

    > >
    > >
    > > I'm guessing that you have redcloth installed both as a gem and as a
    > > library, and that it is being required from both locations, and the
    > > second require is redefining the constants. Guessing. Heavily.
    > >

    > Aha! I know, I know! Case-insensitive Windows file system strikes again,
    > and this time it bites RubyGems in the stern. Amusing :)
    >=20
    > try require'redcloth' instead (note the lower case!), and see for yoursel=

    f.
    >=20
    > This is a RubyGems bug. To reproduce:
    >=20
    > 1. Take fresh Ruby install (must be on Windows)
    > 2. Install RubyGems
    > 3. Install RedCloth by gem install redcloth
    > 4. Modify \ruby\lib\ruby\gems\1.8\gems\RedCloth3.0.3\redcloth.rb by
    > adding puts 'HERE' in the beginning.
    > 5. ruby -w -e "require 'RedCloth'"
    >=20
    > C:\>ruby -w -e "require 'RedCloth'"
    > HERE
    > HERE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:612:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:832:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:1037:
    > warning: amiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/redcloth.rb:815:
    > warning: method redefined; discarding old inline_markdown_link
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:612:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:832:
    > warning: ambiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:1037:
    > warning: amiguous first argument; put parentheses or even spaces
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:169:
    > warning: already initialized constant VERSION
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:170:
    > warning: already initialized constant DEFAULT_RULES
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:242:
    > warning: metod redefined; discarding old initialize
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:254:
    > warning: metod redefined; discarding old to_html
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:311:
    > warning: already initialized constant TEXTILE_TAGS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:324:
    > warning: already initialized constant A_HLGN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:325:
    > warning: already initialized constant A_VLGN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:326:
    > warning: already initialized constant C_CLAS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:327:
    > warning: already initialized constant C_LNGE
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:328:
    > warning: already initialized constant C_STYL
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:329:
    > warning: already initialized constant S_CSPN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:330:
    > warning: already initialized constant S_RSPN
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:331:
    > warning: already initialized constant A
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:332:
    > warning: already initialized constant S
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:333:
    > warning: already initialized constant C
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:335:
    > warning: already initialized constant PUNCT
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:336:
    > warning: already initialized constant HYPERLINK
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:342:
    > warning: already initialized constant SIMPLE_HTML_TAGS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:364:
    > warning: already initialized constant GLYPHS
    > c:/ruby/lib/ruby/gems/1.8/gems/RedCloth-3.0.3/lib/RedCloth.rb:371:
    > warning: alre
    > this causes redcloth.rb to be loaded twice - first from ruby/lib/
    >=20
    > Alex
    >=20
    >=20
    >
     
    Krishna Dole, Aug 19, 2005
    #7
  8. On Fri, 19 Aug 2005 20:17:14 +0900, Krishna Dole <> wrote:

    >>
    >> 1. Take fresh Ruby install (must be on Windows)
    >> 2. Install RubyGems
    >> 3. Install RedCloth by gem install redcloth
    >> 4. Modify \ruby\lib\ruby\gems\1.8\gems\RedCloth3.0.3\redcloth.rb by
    >> adding puts 'HERE' in the beginning.
    >> 5. ruby -w -e "require 'RedCloth'"
    >>


    FWIW, I had a similar experience with a lib, whose name I've forgotten
    (don't you just love this precision), but the problem disappeared after
    I removed an environment variable RUBYOPT (IIRC) which seemed to have
    survived from an *earlier* ruby installation.

    So you might check your environment and remove suspicious RUBY.... variables.

    HTH
    s.
     
    Stefan Schmiedl, Aug 19, 2005
    #8
  9. Stefan Schmiedl wrote:
    > On Fri, 19 Aug 2005 20:17:14 +0900, Krishna Dole <>
    > wrote:
    >
    >>>
    >>> 1. Take fresh Ruby install (must be on Windows)
    >>> 2. Install RubyGems
    >>> 3. Install RedCloth by gem install redcloth
    >>> 4. Modify \ruby\lib\ruby\gems\1.8\gems\RedCloth3.0.3\redcloth.rb by
    >>> adding puts 'HERE' in the beginning.
    >>> 5. ruby -w -e "require 'RedCloth'"
    >>>

    >
    > FWIW, I had a similar experience with a lib, whose name I've forgotten
    > (don't you just love this precision), but the problem disappeared after
    > I removed an environment variable RUBYOPT (IIRC) which seemed to have
    > survived from an *earlier* ruby installation.
    >
    > So you might check your environment and remove suspicious RUBY....
    > variables.
    >
    > HTH
    > s.


    Or you might like to remove double entries in RUBYOPT. I had 'rubygems'
    twice mentioned in RUBYOPT.
    BTW, that happened on a WinXP box running the one-click installer.

    Happy rubying

    Stephan
     
    Stephan Kämper, Aug 19, 2005
    #9
  10. On Aug 19, 2005, at 6:17 AM, Krishna Dole wrote:

    > I get the same double-load on Mac OS 10.3.9:


    I see the same messages when I launch Instiki on TextDrive.

    James Edward Gray II
     
    James Edward Gray II, Aug 19, 2005
    #10
  11. James Edward Gray II wrote:

    > On Aug 19, 2005, at 6:17 AM, Krishna Dole wrote:
    >
    >> I get the same double-load on Mac OS 10.3.9:

    >
    > I see the same messages when I launch Instiki on TextDrive.


    That's for a different reason - you see those when Madeleine replaces
    those things with object space from a snapshot.

    Alex
     
    Alexey Verkhovsky, Aug 19, 2005
    #11
    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.

Share This Page