Forum: JRuby Rubygems error

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
1f77113371c7d36eae5c8a1f10137438?d=identicon&s=25 Pete Helgren (Guest)
on 2008-11-15 00:28
(Received via mailing list)
I am trying to get to the bottom of the following error:

jruby
script/server
/usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems.rb:723:in
`set_paths':
 undefined method `uid' for nil:NilClass
(NoMethodError)
        from
/usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems.rb:719:in
`each'
        from
/usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems.rb:719:in
`set_paths'
        from
/usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems.rb:526:in
`path'
        from
/usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:66:in
`installed_spec_directories'
        from
/usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems/source_index.rb:56:in
`from_installed_gems'

jruby 1.1.5
java 1.5
gem 1.3.1
OS i5/OS AIX PASE

Commenting out line 723 takes care of the issue but I'd rather get a
more permanent fix.

Any ideas as to why the undefined method error is thrown?  Should I post
to a different forum on this?

Thanks,

Pete

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
Ede2aa10c6462f1d825143879be59e38?d=identicon&s=25 Charles Oliver Nutter (Guest)
on 2008-11-16 05:58
(Received via mailing list)
Pete Helgren wrote:
> I am trying to get to the bottom of the following error:
>
> jruby
> script/server
> /usr/local/jruby-1.1.5/lib/ruby/site_ruby/1.8/rubygems.rb:723:in
> `set_paths':
> undefined method `uid' for nil:NilClass
> (NoMethodError)                           from
...
> Any ideas as to why the undefined method error is thrown?  Should I post
> to a different forum on this?

I thought this was supposed to be fixed in RubyGems 1.3.1, which we
shipped in 1.1.5. The problem is RubyGems expecting Etc methods to
return e.g. Passwd struct always if they're implemented, and when we
return nil it's blowing up. We support Etc methods when we're able to
call native code, but it's also valid for Etc methods to return nil when
there's no capability to support them (as is the case on Windows).
RubyGems contains filters for windows, but not for those methods simply
returning nil.

Could you take it up with RubyGems folks? I know they had intended to
fix this for 1.3.1, but perhaps a couple cases snuck through.

- Charlie

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
This topic is locked and can not be replied to.