[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

require net/ssh gem and korundum

Bauduin Raphael

1/1/2005 5:35:00 PM

Hi,

I've installed korundum(KDE bindings) manually and net/ssh as a gem
(just upgraded rubygems to 0.8.4).

Here are the require lines I have:

require 'Korundum'
require 'tailWindow'
require 'sshtail' #generated with rbuic
require 'rubygems' #generated with rbuic
require 'net/ssh'

Everything works as long as I don't require net/ssh. The last require
gives me this error:

/usr/local/lib/site_ruby/1.8/rubygems.rb:263:in `const_missing':
uninitialized constant KDE::Config::CONFIG (NameError)
from /usr/local/lib/site_ruby/1.8/rubygems.rb:263:in `default_dir'
from /usr/local/lib/site_ruby/1.8/rubygems.rb:86:in `dir'
from /usr/local/lib/site_ruby/1.8/rubygems.rb:248:in `set_paths'
from /usr/local/lib/site_ruby/1.8/rubygems.rb:97:in `path'
from
/usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:54:in
`build_paths'
from
/usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:68:in
`search_gempath'
from
/usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:4:in `require'
from ./tail.rb:7


I can use net/ssh in another script, so its installation is fine. Is
there a problem because I use a manually installed lib and a gem in the
same script?

Raph
2 Answers

Richard Dale

1/2/2005 10:39:00 AM

0

Bauduin Raphael wrote:

> Hi,
>
> I've installed korundum(KDE bindings) manually and net/ssh as a gem
> (just upgraded rubygems to 0.8.4).
>
> Here are the require lines I have:
>
> require 'Korundum'
> require 'tailWindow'
> require 'sshtail' #generated with rbuic
> require 'rubygems' #generated with rbuic
> require 'net/ssh'
>
> Everything works as long as I don't require net/ssh. The last require
> gives me this error:
>
> /usr/local/lib/site_ruby/1.8/rubygems.rb:263:in `const_missing':
> uninitialized constant KDE::Config::CONFIG (NameError)
> from /usr/local/lib/site_ruby/1.8/rubygems.rb:263:in
> `default_dir' from /usr/local/lib/site_ruby/1.8/rubygems.rb:86:in
> `dir' from /usr/local/lib/site_ruby/1.8/rubygems.rb:248:in
> `set_paths' from /usr/local/lib/site_ruby/1.8/rubygems.rb:97:in
> `path' from
> /usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:54:in
> `build_paths'
> from
> /usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:68:in
> `search_gempath'
> from
> /usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:4:in `require'
> from ./tail.rb:7
>
>
> I can use net/ssh in another script, so its installation is fine. Is
> there a problem because I use a manually installed lib and a gem in the
> same script?
I tried it and got the same error. Then I moved the rubygems require to
before the Korundum one and it worked ok though:

require 'rubygems'
require_gem 'net-ssh'

require 'Korundum'
....

I haven't actually tried calling methods in the net-ssh package though, so
there still might be incompatibility problems.

-- Richard

Bauduin Raphael

1/2/2005 5:08:00 PM

0

Richard Dale wrote:
> Bauduin Raphael wrote:
>
>
>>Hi,
>>
>>I've installed korundum(KDE bindings) manually and net/ssh as a gem
>>(just upgraded rubygems to 0.8.4).
>>
>>Here are the require lines I have:
>>
>>require 'Korundum'
>>require 'tailWindow'
>>require 'sshtail' #generated with rbuic
>>require 'rubygems' #generated with rbuic
>>require 'net/ssh'
>>
>>Everything works as long as I don't require net/ssh. The last require
>>gives me this error:
>>
>>/usr/local/lib/site_ruby/1.8/rubygems.rb:263:in `const_missing':
>>uninitialized constant KDE::Config::CONFIG (NameError)
>> from /usr/local/lib/site_ruby/1.8/rubygems.rb:263:in
>> `default_dir' from /usr/local/lib/site_ruby/1.8/rubygems.rb:86:in
>> `dir' from /usr/local/lib/site_ruby/1.8/rubygems.rb:248:in
>> `set_paths' from /usr/local/lib/site_ruby/1.8/rubygems.rb:97:in
>> `path' from
>>/usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:54:in
>>`build_paths'
>> from
>>/usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:68:in
>>`search_gempath'
>> from
>>/usr/local/lib/site_ruby/1.8/rubygems/loadpath_manager.rb:4:in `require'
>> from ./tail.rb:7
>>
>>
>>I can use net/ssh in another script, so its installation is fine. Is
>>there a problem because I use a manually installed lib and a gem in the
>>same script?
>
> I tried it and got the same error. Then I moved the rubygems require to
> before the Korundum one and it worked ok though:
>
> require 'rubygems'
> require_gem 'net-ssh'
>
> require 'Korundum'
> ...
>
> I haven't actually tried calling methods in the net-ssh package though, so
> there still might be incompatibility problems.
>

Seems to work indeed. Not sure I'll continue with the gem though...

Raph


> -- Richard