Added unicode exception and forced encoding utf8 to add resilience