开发者

ActionView::Template::Error (Cannot modify SafeBuffer in place) haml devise

开发者 https://www.devze.com 2023-03-29 16:08 出处:网络
After i changed my Gemfile in installed all the gems using bundler i noticed a error: TypeError in Devise/sessions#new

After i changed my Gemfile in installed all the gems using bundler i noticed a error:

TypeError in Devise/sessions#new
Showing /home/mark/workspace/fleet/app/views/layouts/application.html.haml where line # raised:
Cannot modify SafeBuffer in place

开发者_开发百科The server log sais:

16:22:12 Started GET "/users/sign_in" for 127.0.0.1 at 2011-08-22 16:22:12 +0200
16:22:12 action_controller Processing by Devise::SessionsController#new as HTML
16:22:12 active_record SQL (2.4ms)   SELECT a.attname, format_type(a.atttypid, a.atttypmod), d.adsrc, a.attnotnull
 FROM pg_attribute a LEFT JOIN pg_attrdef d
 ON a.attrelid = d.adrelid AND a.attnum = d.adnum
 WHERE a.attrelid = '"users"'::regclass
 AND a.attnum > 0 AND NOT a.attisdropped
 ORDER BY a.attnum
16:22:12 action_view Rendered devise/sessions/new.html.haml within layouts/application (47.8ms)
16:22:12 action_controller Completed 500 Internal Server Error in 101ms

16:22:12 ActionView::Template::Error (Cannot modify SafeBuffer in place):
16:22:12 action_view Rendered /home/mark/.rvm/gems/ruby-1.9.2-head@fleet/gems/actionpack-3.0.9/lib/action_dispatch/middleware/templates/rescues/_trace.erb (1.0ms)
16:22:12 action_view Rendered /home/mark/.rvm/gems/ruby-1.9.2-head@fleet/gems/actionpack-3.0.9/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb (299.0ms)
16:22:12 action_view Rendered /home/mark/.rvm/gems/ruby-1.9.2-head@fleet/gems/actionpack-3.0.9/lib/action_dispatch/middleware/templates/rescues/template_error.erb within rescues/layout (306.6ms)

My app/views/devise/sessions/new.html.haml looks like:

%h2 sign_in

My gem file looks like: source 'http://rubygems.org'

gem 'rails', '3.0.9'
gem 'pg'
gem 'jquery-rails'
gem 'devise', :git => "git://github.com/plataformatec/devise.git"
gem 'capistrano'

gem 'rmagick'
gem 'carrierwave'
gem 'paper_trail'
gem 'kaminari'

gem 'haml'
gem 'cancan'

# FOR XLS MANIPULATION
gem 'rubyzip'
gem 'nokogiri'
gem 'roo'
gem 'to_xls'

I have absolutely no idea what happened. I tried to google and found nothing :-( If anyone had a similar problem or knows the solution for this particular error I would grateful for sharing :)

Thank you in advance! Cheers


Bug in haml. Fixed in version 3.1.2

0

精彩评论

暂无评论...
验证码 换一张
取 消