Shopify / dashing

The exceptionally handsome dashboard framework in Ruby and Coffeescript.
http://shopify.github.com/dashing/
MIT License
10.98k stars 1.18k forks source link

InvalidByteSequenceError on comments.coffee #242

Open ringods opened 11 years ago

ringods commented 11 years ago

I followed the instructions to generate a default dashing folder structure on Mac OS X 10.8.4, using dashing 1.3.1 in RVM with ruby 1.9.3-p448. When browsing to http://localhost:3030/sample, all I get is a black window but with the following error in the Javascript console:

Uncaught Error: Encoding::InvalidByteSequenceError: "\xE2" on US-ASCII
  (in /Users/ringods/Projects/hostbasket/hb-itdev-dashboard/widgets/comments/comments.coffee) application.js:1
(anonymous function)

Dashing seems to read the files as US-ASCII while it should be in UTF-8. The problem is in line 4 with the quoting: "“#{@get('current_comment')?.body}”"

If I remove the comments widget altogether, the sample dashboard loads fine.

andygoldschmidt commented 11 years ago

Same issue here with ruby 2.0.0p247 from rbenv on Mac OS X 10.8. Removing the inner quotes from the above pasted line solved the problem for me.

etmjansen commented 9 years ago

To fix this, you can try adding this to your .bash_profile or .zshrc file

export LANG=en_US.UTF-8
export LC_CTYPE=en_US.UTF-8
export LC_ALL=en_US.UTF-8

Don't forget to reopen the terminal after editing the profile