Sign in through GitHub

Please read for an updated status on RailsCasts:

Learn more or hide this

John Knott's Profile

GitHub User: johnknott

Site: johnknott.co.uk

Comments by John Knott

Avatar

If you are having problems with the Albino gem returning nothing, make sure you are running Pygmentize under Python2.

I was encountering this issue from the command line:

pygmentize -l ruby -f html -O encoding=utf-8 test.rb

*** Error while highlighting:
TypeError: must be str, not bytes
   (file "/usr/lib/python3.2/codecs.py", line 356, in write)

In Arch Linux for example the default Python is Python3.2, installing Pygmentize under Python2.7 solved this for me.