Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.ruby > #4338 > unrolled thread

Digest::Base problem

Started byMartin Hansen <mail@maasha.dk>
First post2011-05-12 05:59 -0500
Last post2011-05-13 06:52 -0500
Articles 3 on this page of 23 — 5 participants

Back to article view | Back to comp.lang.ruby


Contents

  Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 05:59 -0500
    Re: Digest::Base problem Phillip Gawlowski <cmdjackryan@googlemail.com> - 2011-05-12 06:29 -0500
      Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 06:55 -0500
        Re: Digest::Base problem Phillip Gawlowski <cmdjackryan@googlemail.com> - 2011-05-12 07:14 -0500
          Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 07:45 -0500
            Re: Digest::Base problem Phillip Gawlowski <cmdjackryan@googlemail.com> - 2011-05-12 07:53 -0500
              Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 08:02 -0500
                Re: Digest::Base problem Phillip Gawlowski <cmdjackryan@googlemail.com> - 2011-05-12 08:25 -0500
                  Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 08:36 -0500
                    Re: Digest::Base problem Phillip Gawlowski <cmdjackryan@googlemail.com> - 2011-05-12 08:43 -0500
                      Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 08:57 -0500
    Re: Digest::Base problem brabuhr@gmail.com - 2011-05-12 08:07 -0500
      Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 08:22 -0500
        Re: Digest::Base problem brabuhr@gmail.com - 2011-05-12 09:15 -0500
          Re: Digest::Base problem brabuhr@gmail.com - 2011-05-12 09:26 -0500
            Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 09:39 -0500
              Re: Digest::Base problem Phillip Gawlowski <cmdjackryan@googlemail.com> - 2011-05-12 09:52 -0500
                Re: Digest::Base problem Linda Metcalfe <lmetcalfe@connextions.com> - 2011-05-12 10:06 -0500
                  Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-12 10:19 -0500
              Re: Digest::Base problem brabuhr@gmail.com - 2011-05-12 10:58 -0500
    Re: Digest::Base problem Brian Candler <b.candler@pobox.com> - 2011-05-13 03:17 -0500
      Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-13 06:23 -0500
        Re: Digest::Base problem Martin Hansen <mail@maasha.dk> - 2011-05-13 06:52 -0500

Page 2 of 2 — ← Prev page 1 [2]


#4468

FromBrian Candler <b.candler@pobox.com>
Date2011-05-13 03:17 -0500
Message-ID<8a4bfe3b706c6ee624e806adf127beba@ruby-forum.com>
In reply to#4338
Just one thing to check: you don't happen to have a file called 
"digest.rb" lying around in the current directory?

It's tempting when writing a test program to exercise the digest library 
to call it "digest.rb". But then "require 'digest'" will fail because it 
will load the wrong file :-)

One way to diagnose this is to find digest.so on your system (e.g. 
"locate digest.so") and then require it with a full path: e.g.

irb(main):001:0> require '/usr/lib/ruby/1.8/x86_64-linux/digest.so'
=> true
irb(main):002:0> Digest::Base
=> Digest::Base

-- 
Posted via http://www.ruby-forum.com/.

[toc] | [prev] | [next] | [standalone]


#4481

FromMartin Hansen <mail@maasha.dk>
Date2011-05-13 06:23 -0500
Message-ID<7110678d720429eaceab99a79a32ba05@ruby-forum.com>
In reply to#4468
Brian Candler wrote in post #998468:
> Just one thing to check: you don't happen to have a file called
> "digest.rb" lying around in the current directory?

aaaaaaargh!

AAAAAAAARGH!!!


Yes! That's it!!! $RUBYLIB includes a dir with another digest.rb.

So - how can avoid this conflict? I prefer not to rename the file if 
avoidable.


(BIG THANKS)


Martin

-- 
Posted via http://www.ruby-forum.com/.

[toc] | [prev] | [next] | [standalone]


#4482

FromMartin Hansen <mail@maasha.dk>
Date2011-05-13 06:52 -0500
Message-ID<0458590b3d297eeb786e1f8d5f8f0217@ruby-forum.com>
In reply to#4481
OK, this comes down to my code being badly organized. I will get right 
at it.

Case closed.


BIG THANKS to all you helpers!


(time to help myself)


Cheers,



Martin

-- 
Posted via http://www.ruby-forum.com/.

[toc] | [prev] | [standalone]


Page 2 of 2 — ← Prev page 1 [2]

Back to top | Article view | comp.lang.ruby


csiph-web