# Error running gems:install on edge

**URL:** <https://www.ruby-forum.com/t/error-running-gems-install-on-edge/160387>\
**Category:** Rails\
**Created:** [February 15, 2009, 7:50pm UTC](https://www.ruby-forum.com/t/error-running-gems-install-on-edge/160387 "2009-02-15T19:50:21Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ARod](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/d07c76/32.png) [@ARod](https://www.ruby-forum.com/u/ARod)\
**Post date:** [February 15, 2009, 7:50pm UTC](https://www.ruby-forum.com/t/error-running-gems-install-on-edge/160387/1 "2009-02-15T19:50:21Z")

</div>

Hi,

I’m trying out the new features in Rails 2.3.0 RC1. Especially  
interested in the new “Nested Forms” functionality. I’m having a  
problem when installing gems into my project. When adding a gem (e.g.  
“mislav-will\_paginate”) to the “config/environment.rb” and running:

rake gems:install

I get the following error.

===========================================  
rake aborted!  
A key is required to write a cookie containing the session data. Use  
config.action\_controller.session = { :key =\> “\_myapp\_session”, :secret  
=\> “some secret phrase” } in config/environment.rb

# (See full trace by running task with --trace)

Is anybody out there having this problem?

In Rails edge the environment.rb no longer has the session key, all  
that has been changed and moved to a separate initializer. One thing I  
discovered is that the error only happens for gems that are not  
already installed in the local gems repo.

Thx,

–Alex

---

<div class="post-metadata">

**Author:** ![ARod](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/d07c76/32.png) [@ARod](https://www.ruby-forum.com/u/ARod)\
**Post date:** [February 16, 2009, 9:17pm UTC](https://www.ruby-forum.com/t/error-running-gems-install-on-edge/160387/2 "2009-02-16T21:17:34Z")

</div>

Have the vey same problem.  
No clue yet on how to solve it

---

<div class="post-metadata">

**Author:** ![ARod](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/d07c76/32.png) [@ARod](https://www.ruby-forum.com/u/ARod)\
**Post date:** [February 18, 2009, 2:02am UTC](https://www.ruby-forum.com/t/error-running-gems-install-on-edge/160387/3 "2009-02-18T02:02:25Z")

</div>

This has been filed as #1750 on the Lighthouse for a bit (http://  
[#1750 session\_store initializer causes rake:gems tasks to break - Ruby on Rails - rails](http://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/1750)).  
Can you give the patch I posted (towards the bottom of the ticket) a  
try?

–Matt J.
