# Rubygems freezes with expand\_path error

**URL:** <https://www.ruby-forum.com/t/rubygems-freezes-with-expand-path-error/189037>\
**Category:** Ruby\
**Created:** [May 22, 2010, 6:46pm UTC](https://www.ruby-forum.com/t/rubygems-freezes-with-expand-path-error/189037 "2010-05-22T18:46:45Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![steux](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d26b3c/32.png) [@steux](https://www.ruby-forum.com/u/steux)\
**Post date:** [May 22, 2010, 6:46pm UTC](https://www.ruby-forum.com/t/rubygems-freezes-with-expand-path-error/189037/1 "2010-05-22T18:46:45Z")

</div>

Hi,  
Rubygems went crazy.  
Here is the command sequence:

# gem list

\*\*\* LOCAL GEMS \*\*\*

actionmailer (2.3.5)  
actionpack (2.3.5)  
activerecord (2.3.5)  
activeresource (2.3.5)  
activesupport (2.3.5)  
calendar\_date\_select (1.16.1)  
cgi\_multipart\_eof\_fix (2.5.0)  
daemons (1.0.10)  
eventmachine (0.12.10)  
fastthread (1.0.7)  
gem\_plugin (0.2.3)  
image\_science (1.2.1)  
memcache-client (1.8.3)  
mime-types (1.16)  
mongrel (1.1.5)  
mysql (2.8.1)  
rack (1.0.1)  
rails (2.3.5)  
rake (0.8.7)  
rcov (0.9.8)  
rspec (1.3.0)  
ruby-fcgi (0.8.9)  
ruby-lsapi (4.0)  
RubyInline (3.8.4)  
sqlite3-ruby (1.2.5)  
starling (0.10.1)  
thin (1.2.7)  
webroar (0.3.1)  
will\_paginate (2.3.12)  
ZenTest (4.3.1)

# webroar stop

Stopping webroar-head … done.  
Stopping webroar-analyzer process … done.

# webroar uninstall

Removing executables … done.  
Removing admin panel application database … done.  
WebROaR uninstalled successfully.  
Removing files …  
Removing log rotate file … done.  
Removing service script … done.

# gem list

/usr/lib/ruby/1.8/rubygems.rb:471:in `expand_path': No such file or directory - getcwd (Errno::ENOENT) from /usr/lib/ruby/1.8/rubygems.rb:471:in`find\_files’  
from /usr/lib/ruby/1.8/rubygems.rb:470:in `map' from /usr/lib/ruby/1.8/rubygems.rb:470:in`find\_files’  
from /usr/lib/ruby/1.8/rubygems.rb:1103  
from /usr/bin/gem:8:in `require’  
from /usr/bin/gem:8

what happened?

regards

---

<div class="post-metadata">

**Author:** ![steux](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d26b3c/32.png) [@steux](https://www.ruby-forum.com/u/steux)\
**Post date:** [May 22, 2010, 11:36pm UTC](https://www.ruby-forum.com/t/rubygems-freezes-with-expand-path-error/189037/2 "2010-05-22T23:36:56Z")

</div>

> ```
> from /usr/bin/gem:8
> 
> ```
> 
> what happened?
> 
> ## regards
> 
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).

Looks like the current working directory for the ruby process was erased  
as part of the earlier gem uninstall. “getcwd (Errno::ENOENT)”

---

<div class="post-metadata">

**Author:** ![steux](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d26b3c/32.png) [@steux](https://www.ruby-forum.com/u/steux)\
**Post date:** [May 22, 2010, 11:42pm UTC](https://www.ruby-forum.com/t/rubygems-freezes-with-expand-path-error/189037/3 "2010-05-22T23:42:46Z")

</div>

After uninstalling rubygems and installing it again, it worked 🙂

James H.on wrote:

> > ```
> > from /usr/bin/gem:8
> > 
> > ```
> > 
> > what happened?
> > 
> > ## regards
> > 
> > Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).
> 
> Looks like the current working directory for the ruby process was erased  
> as part of the earlier gem uninstall. “getcwd (Errno::ENOENT)”

---

<div class="post-metadata">

**Author:** ![steux](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/d26b3c/32.png) [@steux](https://www.ruby-forum.com/u/steux)\
**Post date:** [May 26, 2010, 4:59am UTC](https://www.ruby-forum.com/t/rubygems-freezes-with-expand-path-error/189037/4 "2010-05-26T04:59:51Z")

</div>

On May 22, 2010, at 14:42, Bruno S. wrote:

> After uninstalling rubygems and installing it again, it worked 🙂

That didn’t fix it.

Your current directory disappeared cd ~ (or similar) fixed it.
