# Rails 2.2.2 and Interlock plugin

**URL:** <https://www.ruby-forum.com/t/rails-2-2-2-and-interlock-plugin/156921>\
**Category:** Rails\
**Created:** [January 5, 2009, 11:34am UTC](https://www.ruby-forum.com/t/rails-2-2-2-and-interlock-plugin/156921 "2009-01-05T11:34:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rob](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/838e76/32.png) [@rob](https://www.ruby-forum.com/u/rob)\
**Post date:** [January 5, 2009, 11:34am UTC](https://www.ruby-forum.com/t/rails-2-2-2-and-interlock-plugin/156921/1 "2009-01-05T11:34:26Z")

</div>

Hi there,

Does anyone use the Interlock plugin and got it to work with Rails  
2.2.2. I am currently upgrading our app to Rails 2.2.2 and its been a  
pretty nice transition so far until I kept getting the ‘can’t update  
frozen hash’ errors when calling update\_attributes on a (in this case)  
User object. We are using Interlock for caching result from  
ActiveRecord. We’re not doing anything particularly fancy.

@user = User.find(params[:id])  
@user.update\_attributes(params[:user])

The @user object is showing as frozen directly after the find, it  
appears that when read from the interlock the object is frozen. The only  
way around this I can see is to remove the plugin or use  
User.find(params[:id], {}) to skip the cache. Although this problem will  
likely re-occur all over the application. The strange thing is I cannot  
replicate this in the console, in a controller test or by calling  
User.send(:find\_by\_cache, [1]) directly. It only occurs when called  
within my controller so I am quite stumped to be honest.

Does anyone else have or has any one else seen this problem?

Cheers

RobL
