You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tested with pysrt 1.0.1 (Debian buster 10.3 and Ubuntu Bionic 18.04 default pkg) and pypip version which is also 1.0.1 (for both debian buster and ubuntu bionic)
I tried with the github version (1.1.2) but somehow I can't make that one work.
I have a series of 6 utf-8 based srt files in Dutch.
If I check them I see
srt shift -36s500ms checkfile.srt > checkfile2.srt
Traceback (most recent call last):
File "/usr/bin/srt", line 9, in <module>
load_entry_point('pysrt==1.0.1', 'console_scripts', 'srt')()
File "/usr/lib/python2.7/dist-packages/pysrt/commands.py", line 215, in main
SubRipShifter().run(sys.argv[1:])
File "/usr/lib/python2.7/dist-packages/pysrt/commands.py", line 136, in run
self.arguments.action()
File "/usr/lib/python2.7/dist-packages/pysrt/commands.py", line 155, in shift
self.input_file.write_into(self.output_file)
File "/usr/lib/python2.7/dist-packages/pysrt/srtfile.py", line 247, in write_into
output_file.write(string_repr)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 35: ordinal not in range(128)
The character is "é" in below string (I assume): Oké, kom mee.
And 20 minutes later ..... :(
After having downloaded the git repo, I did not uninstall the pip and pip3 installed versions correctly.
After having done that and do a sudo python3 ./setup.py install from the git repo, it installs correctly and works correctly.
Tested with pysrt 1.0.1 (Debian buster 10.3 and Ubuntu Bionic 18.04 default pkg) and pypip version which is also 1.0.1 (for both debian buster and ubuntu bionic)
I tried with the github version (1.1.2) but somehow I can't make that one work.
I have a series of 6 utf-8 based srt files in Dutch.
If I check them I see
If I try to convert them, I get:
The character is "é" in below string (I assume):
Oké, kom mee.
I already tried multiple iconv conversions like
and more (nonsense) conversions, just to try. But none works.
My default python is Python 2.7.16.
When changing to python3 (3.7.3), I get
ModuleNotFoundError: No module named 'pysrt'
The text was updated successfully, but these errors were encountered: