Closed hey0wing closed 3 years ago
Hi @hey0wing thanks for filing, trying to replicate, can you specific the following:
where this error is raised/which code you are trying to run? (e.g. copy full error trace). I also assume you are on Windows?
Also based on the error it seems that you would need the encoding to be set to 'cp950', not utf-8, right?
If so, we might be able to address. Thanks
OS: Windows,
Usage: python -m textgrid_convert -i transcription.srt
The problem:
I was trying to convert a srt with Chinese text (utf-8
based) to textgrid, but the convert_to_txtgrid
function did not specify encoding="utf-8
in with open(file) as sourceFile:
. Therefore, the default open
treat Chinese character as cp950
instead of utf-8
.
After I failed to convert the file, I uninstalled the package already and sorry that the problem is not replicable. Thanks!
Could not replicate -- all file operations I could find (grep) use an explicit utf-8
encoding
Please specify the
encoding="utf-8"
inconvert_to_txtgrid
function