rubinius/rubinius — Issue #1470: Undefined method 'join' on an instance of String (NoMethodError)
Author: dyba
Created: 2011-12-24 05:58:43+00:00
State: open

# The Problem

I get the following error:

```
An exception occurred running /Users/danieldyba/.rvm/rubies/rbx-head/lib/bin/gem.rb
undefined method `join' on an instance of String. (NoMethodError)
```

## Reproducing the error

To reproduce this error, you will need to have the latest version of RVM. Then, install rubinius:

```
rvm install rbx
```
Copy the global gemset from a ruby installation 1.9.3-p0 for example.

```
rvm gemset copy 1.9.3@global rbx@MyGemset
```
Then, run the ```gem list``` command to view your gems and you will get the following error with backtrace:

```
[ ~/Rubinius ] >_ gem list
An exception occurred running /Users/danieldyba/.rvm/rubies/rbx-head/lib/bin/gem.rb
undefined method `join' on an instance of String. (NoMethodError)

Backtrace:
Kernel(String)#join (method_missing) at kernel/delta/kernel.rb:79
Gem::Specification#lib_dirs_glob at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems/specification.rb:1392
Gem::Specification#matches_for_glob at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems/specification.rb:1460
{ } in Gem.find_files at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems.rb:481
{ } in Enumerable(Class)#collect at kernel/common/enumerable18.rb:16
{ } in Gem::Specification.each at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems/specification.rb:410
Array#each at kernel/bootstrap/array.rb:66
Gem::Specification.each at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems/specification.rb:409
Enumerable(Class)#map (collect) at kernel/common/enumerable18.rb:16
Gem.find_files at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems.rb:480
Gem.load_plugins at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems.rb:1080
Object#__script__ at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems/gem_runner.rb:86
Rubinius::CodeLoader.require at kernel/common/codeloader.rb:205
Kernel(Object)#gem_original_require (require) at kernel/common/kernel.rb:660
Kernel(Object)#require at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/rubygems/custom_require.rb:36
Object#__script__ at /Users/danieldyba/.rvm/rubies/rbx-head
/lib/bin/gem.rb:9
Rubinius::CodeLoader#load_script at kernel/delta/codeloader.rb:65
Rubinius::CodeLoader.load_script at kernel/delta/codeloader.rb:107
Rubinius::Loader#script at kernel/loader.rb:665
Rubinius::Loader#main at kernel/loader.rb:820
```