Closed Aufree closed 1 year ago
somebody will get an error when not import os
module, just like this:
... Translating chunk. 0 %
... Translating chunk. 9 %
... Translating chunk. 19 %
... Translating chunk. 29 %
... Translating chunk. 39 %
... Translating chunk. 48 %
... Translating chunk. 58 %
... Translating chunk. 68 %
... Translating chunk. 77 %
... Translating chunk. 87 %
... Translating chunk. 97 %
... Translation done
Traceback (most recent call last):
File "sr_translator.py", line 15, in <module>
srt.save(f"{os.path.splitext(filepath)[0]}_translated.srt")
^^
NameError: name 'os' is not defined
why?