2013-02-08 84 views
1

我遇到了一個問題,同時在生產環境中預編譯資產。Rake資產:預編譯問題。解析錯誤

AssetSync: using default configuration from built-in initializer 
rake aborted! 
Caught Encoding::CompatibilityError at '["ok","/*!\n * jQuery': incompatible encoding regexp match (ASCII-8BIT regexp with UTF-8 string) 
    (in /home/rails_work/bunk1_dev/app/assets/javascripts/active_admin.js) 
/usr/local/rvm/gems/[email protected]/gems/json_pure-1.7.6/lib/json/pure/parser.rb:242:in `rescue in parse_string' 
/usr/local/rvm/gems/[email protected]/gems/json_pure-1.7.6/lib/json/pure/parser.rb:213:in `parse_string' 
/usr/local/rvm/gems/[email protected]/gems/json_pure-1.7.6/lib/json/pure/parser.rb:257:in `parse_value' 
/usr/local/rvm/gems/[email protected]/gems/json_pure-1.7.6/lib/json/pure/parser.rb:121:in `parse' 
/usr/local/rvm/gems/[email protected]/gems/json_pure-1.7.6/lib/json/common.rb:155:in `parse` 

任何幫助,將不勝感激

回答

0

我已經解決了這個問題,這個問題是json_pure寶石預編譯有關。只需從代碼中刪除「require'json/pure'」並應用「require'json'」。希望答案能夠幫助其他人。

謝謝