Got error 'invalid UTF-8 string at offset 7' from regexp